aboutsummaryrefslogtreecommitdiffstats
path: root/docker/app/scripts/migrate.sh
diff options
context:
space:
mode:
Diffstat (limited to 'docker/app/scripts/migrate.sh')
-rwxr-xr-xdocker/app/scripts/migrate.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/docker/app/scripts/migrate.sh b/docker/app/scripts/migrate.sh
new file mode 100755
index 00000000..94b5f7c4
--- /dev/null
+++ b/docker/app/scripts/migrate.sh
@@ -0,0 +1,10 @@
+#!/usr/bin/env bash
+
+echo --- Applying migrations ---
+python manage.py migrate --verbosity 1
+
+echo --- Collecting static files ---
+python manage.py collectstatic --no-input --clear --verbosity 0
+
+echo --- Starting uwsgi ---
+exec "$@" # This runs the CMD at the end of the Dockerfile