This project consists of:
-
Flask simple application forked from here https://github.com/mjhea0/flask-tracking
-
Dockerfile - instructions for building our flask app docker image based on python official image.
- Adding flask app files
- Installing dependencies from requirements.xml file
- Exposing 5000 port of which the app listens to
- Running run.py by default which starts flask HTTP server
- Requirements.xml is copied first in order to leverage docker caching (faster build) - dockerfile best practices
-
.travis.yml - travis-ci.com CI/CD stages
- Building python app and running tests
- Building docker image out of the docker file and pushing it to repository
- Deploying docker image to docker hub repository by executing push_docker_image.sh script
-
play_flask_container.yml - Ansible-playbook, provisioning flask app on a remote host
- docker login task
- docker run container task
- For Ansible provisioning I have been using DigitalOcean droplet
link to app - http://68.183.71.133:5000/