Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Beginning DevOps with Docker
  • Table Of Contents Toc
Beginning DevOps with Docker

Beginning DevOps with Docker

By : Muli
3.9 (7)
close
close
Beginning DevOps with Docker

Beginning DevOps with Docker

3.9 (7)
By: Muli

Overview of this book

Making sure that your application runs across different systems as intended is quickly becoming a standard development requirement. With Docker, you can ensure that what you build will behave the way you expect it to, regardless of where it's deployed. By guiding you through Docker from start to finish (from installation, to the Docker Registry, all the way through to working with Docker Swarms), we’ll equip you with the skills you need to migrate your workflow to Docker with complete confidence.
Table of Contents (5 chapters)
close
close

Managing Multiple Containers and Distributed Application Bundles


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/:

Note

Refer the complete code placed at Code/Lesson-2/django-docker-compose.yml.

Go to https://goo.gl/H624J1 to access the code.

Improve a Docker Workflow

To give more context on how docker-compose is involved and how it improves a Docker workflow.

  1. Create a new directory and name it django_docker.

  2. 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.

  3. Create a new Dockerfile and add the content in the Dockerfile script provided.

  4. Create a requirements file; simply copy the django-requirements.txt file provided.

  5. Run docker-compose up and observe the logs.

Notice that we are able to spin up both containers...

CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
Beginning DevOps with Docker
notes
bookmark Notes and Bookmarks search Search in title playlist Add to playlist font-size Font size

Change the font size

margin-width Margin width

Change margin width

day-mode Day/Sepia/Night Modes

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY

Submit Your Feedback

Modal Close icon
Modal Close icon
Modal Close icon