Skip to content

Commit

Permalink
run setup script on start
Browse files Browse the repository at this point in the history
  • Loading branch information
helrond committed Nov 10, 2018
1 parent a59eea8 commit 35de56a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,17 @@

# Apply database migrations
../wait-for-it.sh db:5432 -- echo "Apply database migrations"
python manage.py migrate
python manage.py makemigrations && python manage.py migrate

if [ ! -f zodiac/config.py ]; then
echo "Creating config file"
cp zodiac/config.py.example zodiac/config.py
fi

# Create initial organizations and users
echo "Setting up applications and services"
python manage.py shell < ../setup_services.py

#Start server
echo "Starting server"
python manage.py runserver 0.0.0.0:8001

0 comments on commit 35de56a

Please sign in to comment.