This projects include code and notes used in the demonstrations shown during the "Containers-in-Depth" lecture given as part of the "Open Source development" course.
The slides for the lecture could be found in Google Docs.
- This repository mostly consists of a Django web application used to demonstrate running a moderately-complex application in a container. This application is the same one developed when one works on the Django Girls tutorial.
- This repository also contains Dockerfiles, Ansible playbooks, Vagrantfiles and other files used to demonstrate how to build and run the application container in various ways.
- The
wsgi-app
directory contains a tiny Python web app used in demonstrations where using a fully fledged app would be cumbersome. - Finally, the
demonstrations
directory contains notes used when giving the actual demonstrations in class.
The demonstrations had been designed to allow students to follow along on their own machines in class. Doing so, however requires some tools to be installed on the students' computers before going into class.
Following is a list of the required tools ans settings:
- Docker absolutely must be installed and ready for use in order to follow any of the demonstrations. There are ways to install Docker on Windows or MAC, but since students had issues with this in the past I now recommend setting up a Linux VM with VirtualBox or Vagrant and installing the Docker package there.
- To practice pushing images to remote registries, you need a quay.io account. You can create one here, or simply sign-in with your existing Google or GitHub accounts
- To run the Django test application locally, as well as
Docker compose and Ansible, you need to have:
- Python (3.6.8 or newer). Installation instructions can be found here for Windows and here for Mac. For Linux you should install Python 3.6.8 or newer using your package manager
- Pipenv. Instructions for installing it are here, but
please don't bother trying to use Homebrew if you're not using a Mac.
Instead, either use
pip
with the--user
option (pip
should be included with your Python installation), or use Pipx followig the instructions here.
- If you want to try running S2i locally, you can download it
here and simply extract the single file you will find in the archive
suitable for your OS to some location that is pointed to by
$PATH
- To run the Vagrant-based demonstrations follow the instructions
here to install it. You'll also need VirtualBox (Instructions
here, but if you're usine Windows, please see the note below)
or, alternatively if using Linux, you can use the
vagrant-libvirt plugin to use the native virtualization system
(Installation instruction are in the main
README.md
file)
This list of tools may seem extensive, but most of these are standard tools you'll find on any developer's workstation. The major tools have been used in other parts of the course already, so they are hopefully already installed on most students` computers.