A simple boilerplate providing a complete setup to start a new flask
project
To build the docker image, simply open a terminal and run the following command:
docker-compose build
To run the image in a docker container, simply open a terminal and run the following command:
docker-compose up flaskdockerstarterkit
The project will be available on the following URI: http://127.0.0.1:5000
To run the image with the VSCode debugger please follow these steps:
- Run the command
docker-compose up debugger
in your terminal,debugpy
will wait for the VSCode debugger to attach before running theflask
server - Go to VSCode
Run and Debug
Section - Select the
▶️
button with the optionPython: Remote Attach
And the flask
server will run successfully, happy debugging ! 🚀
To run the tests, please run the following command in your terminal:
docker-compose up test-runner
You need to have a .env
file containing all the keys and values required.
You can refer to the .env.example
file
- Up and running
flask
server - Containerized application
- Unit tests
- VSCode debugger with hot reload