The purpose of this project is to simplify the process of configuring Flask using Docker. This docker setup contains the minimal configuration of Flask application.
-
Copy
.env.example
file to.env
cp .env.example .env
-
Override environment variables in
.env
file -
Start the project
docker-compose up -d
-
Visit http://localhost:8080/
docker-compose exec container_name bash
# E.g.
# To get into container with python and application
docker-compose exec app bash
# In app container.
# View list of available commands
flask db
# Create migration for all new models.
flask db init
# Apply new migrations
flask db migrate
Project contain 3 components:
- Nginx - to serve static files
- Gunicorn - as WSGI interface for python apps.
- Flask app itself - contains all project business logic
MIT License: see the LICENSE
file.