-
Book Overview & Buying
-
Table Of Contents
Beginning DevOps with Docker
By :
This is the docker-compose.yml for running a Django application. A similar application can be found in the docker-compose documentation under the Django example.
Download the Django example from: ttps://docs.docker.com/compose/django/:

Refer the complete code placed at Code/Lesson-2/django-docker-compose.yml.
Go to https://goo.gl/H624J1 to access the code.
To give more context on how docker-compose is involved and how it improves a Docker workflow.
Create a new directory and name it django_docker.
In the django-docker directory, create a new docker-compose.yml and add the information in the figure above, or in the django-docker-compose.yml script provided.
Create a new Dockerfile and add the content in the Dockerfile script provided.
Create a requirements file; simply copy the django-requirements.txt file provided.
Run docker-compose up and observe the logs.
Notice that we are able to spin up both containers...
Change the font size
Change margin width
Change background colour