some tweaks for running on the server with docker w/ burnettk

This commit is contained in:
jasquat 2022-06-01 15:49:05 -04:00
parent c6131a04d3
commit 5b51030a40
3 changed files with 15 additions and 6 deletions

View File

@ -25,9 +25,11 @@ if [[ -z "$port" ]]; then
port=7000
fi
# THIS MUST BE THE LAST COMMAND!
if [ "${APPLICATION_ROOT:-}" = "/" ]; then
exec poetry run gunicorn --bind "0.0.0.0:$PORT0" wsgi:app
else
exec poetry run gunicorn -e SCRIPT_NAME="$APPLICATION_ROOT" --bind "0.0.0.0:$PORT0" wsgi:app
additional_args=""
if [[ "${APPLICATION_ROOT:-}" != "/" ]]; then
additional_args="${additional_args} -e SCRIPT_NAME=${APPLICATION_ROOT}"
fi
# THIS MUST BE THE LAST COMMAND!
exec poetry run gunicorn ${additional_args} --bind "0.0.0.0:$PORT0" --workers=3 --timeout 90 --log-level debug wsgi:app

View File

@ -12,4 +12,9 @@ if [[ -z "${BPMN_SPEC_ABSOLUTE_DIR:-}" ]]; then
export BPMN_SPEC_ABSOLUTE_DIR="$script_dir/../../sample-process-models"
fi
docker compose up --build
additional_args=""
if [[ "${RUN_WITH_DAEMON:-}" != "false" ]]; then
additional_args="${additional_args} -d"
fi
docker compose up --build $additional_args

View File

@ -13,6 +13,8 @@ services:
- '7001:3306'
volumes:
- spiffworkflow_backend:/var/lib/mysql
healthcheck:
test: mysql --user=root --password=St4g3Th1515 -e 'select 1' spiffworkflow_backend_staging
spiffworkflow-backend:
container_name: spiffworkflow-backend