Skip to content

Commit

Permalink
In docker-entrypoint ensure tables exist
Browse files Browse the repository at this point in the history
  • Loading branch information
Allen Short authored and jezdez committed Aug 19, 2019
1 parent e5e926b commit 34e03fe
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions bin/docker-entrypoint
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
set -e

worker() {
/app/manage.py db upgrade
WORKERS_COUNT=${WORKERS_COUNT:-2}
QUEUES=${QUEUES:-queries,scheduled_queries,celery,schemas}
WORKER_EXTRA_OPTIONS=${WORKER_EXTRA_OPTIONS:-}
Expand All @@ -11,6 +12,7 @@ worker() {
}

scheduler() {
/app/manage.py db upgrade
WORKERS_COUNT=${WORKERS_COUNT:-1}
QUEUES=${QUEUES:-celery}
SCHEDULE_DB=${SCHEDULE_DB:-celerybeat-schedule}
Expand All @@ -31,6 +33,7 @@ dev_worker() {
}

server() {
/app/manage.py db upgrade
# Recycle gunicorn workers every n-th request. See http://docs.gunicorn.org/en/stable/settings.html#max-requests for more details.
MAX_REQUESTS=${MAX_REQUESTS:-1000}
MAX_REQUESTS_JITTER=${MAX_REQUESTS_JITTER:-100}
Expand Down

0 comments on commit 34e03fe

Please sign in to comment.