docker-compose for Pythonistas





We all have at least heard about the terms containers, docker, etc. in today's times and the benefit, they bring to the deployment cycle of a web app. In this workshop, we will try to build the functionality of our server from the ground up using dockers as a dev env. This usage of containers is important as today most of the devs work on multiple services(thanks to microservice bloom) each requiring its own set of external dependencies which requires specific flags or settings to be set, instead of polluting our system containers help us to run almost any complex requirement app with zero setups.

If you are a web developer then one big hurdle you could have faced when you started on a new project in your firm relating to setting up environments for your dev and test area, i.e cloning this codebase, setting up MySQL/Postgres, using XYZ other components, generating builds and all. Well with the help of containers you don't need to do that as in short, they help you keep your infrastructure as code, meaning very similar prod and dev environments, because why not. Using containers is also a learning for the separation of concerns of your overall system. You start thinking about things that can run separately on individual hosts, rather than a big huge pile of matter on a single host. To a large extent, understanding of containers helps in scaling your infrastructure easily.

We will use docker-compose a fantastic tool built-in python to orchestrate our containers. We will go full-on with something called Extreme Programming, using Test-Driven-Development and Pair-Programming

Basic Outline of the talk

  1. We will start with the advantages of using Docker in the development cycle.
  2. We will set up a project structure for our server.
  3. Prepare our dependencies.
  4. Start writing tests, and onwards.

Who is this talk for

  • Python web developers.
  • Developers who need multiple versions of external dependencies to be installed locally as part of their work.
  • Developers who are interested in the TDD way.

Key Takeaways

  • Implementing a REST API in Flask.
  • Using docker for development and bringing up external dependencies.
  • Using Test-Driven Development.


Basic knowledge of web development. Basic knowledge of Docker. Github and a GitLab account, no paid service is required.

Content URLs:

GitHub Repo to be used is, we will be building on just the server-side of things here, using our client as-is in the repo.

Slides can be found at:-

Speaker Info:

I work as a Dev-Ops engineer in Vymo, prior to that I have worked at and have over 2.5 years of experience in Web Services. Graduated in 2017 from Kamla Nehru Institute of Technology with a Bachelor's degree in Computer Science and Engineering. Developing and consuming my own APIs for almost a year now. I prefer a raspberry pi over the cloud to host my home-scale services for personal use. In my free time, I prefer stargazing. Currently working on combining the power of python-ecosystem to boost my deployment.

Speaker Links:

Section: Web development
Type: Workshop
Target Audience: Intermediate
Last Updated: