Skip to content

Instantly share code, notes, and snippets.

@Nagasaki45
Created March 1, 2016 18:39
Show Gist options
  • Select an option

  • Save Nagasaki45/9aed10b837612f385bc7 to your computer and use it in GitHub Desktop.

Select an option

Save Nagasaki45/9aed10b837612f385bc7 to your computer and use it in GitHub Desktop.
Building and running django app with docker-compose
# Build the three containers
# Images are automatically fetched, if necessary, from docker hub
docker-compose build
# Start a new web container to run migrations
# Use --rm to remove the container when the command completes
docker-compose run --rm web python manage.py migrate
# Run everything in the background with -d
docker-compose up -d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment