Skip to content

Instantly share code, notes, and snippets.

@erangaeb
Last active February 13, 2017 09:42
Show Gist options
  • Save erangaeb/cebab05e4dc3b4c9fc8c4e7db8b552f0 to your computer and use it in GitHub Desktop.
Save erangaeb/cebab05e4dc3b4c9fc8c4e7db8b552f0 to your computer and use it in GitHub Desktop.
docker entrypoint for django app
#!/bin/bash
# apply database migrations
# didn't use 'south' in order to keep things simple
# with south db migaration would be like below
# python manage.py migrate tastypi
# python manage.py migrate south
# python manage.py migrate api
#
#
# --noinput used to sync without creating superuser
python manage.py syncdb --noinput
# start server
python manage.py runserver 0.0.0.0:8000
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment