atst/script/dev_server_WIP
2018-07-10 10:55:28 -04:00

32 lines
485 B
Bash
Executable File

#!/bin/bash
# script/dev_server: Launch a local dev version of the server in the background
#
# WIP
#
source "$(dirname "${0}")"/../script/include/global_header.inc.sh
# Create a function to trap signals with
reap() {
kill -TERM "${child}"
sleep 0.1
exit
}
# Register trap
trap reap TERM INT
# Set server launch related environment variables
DEBUG=1
LAUNCH_ARGS="$*"
# Launch the app
source ./script/server
# Capture the PID of the child process
child=$!
wait $child