Gentelella template powered by Flask
status | |
---|---|
master | |
develop |
Gentelella is a free to use Bootstrap admin template.
This project integrates Gentelella with Flask using:
Flask-gentelella also comes with a robust CI/CD pipeline using:
tests
folder).Dockerfile
showing how to containerize the application with gunicorn, and a Docker image available on dockerhub, and integrated to the CI/CD pipeline (see instructions below).docker-compose
file to start Flask-gentelella with nginx
, gunicorn
and a PostgreSQL database.Here is an example of a real project implemented using Flask-Gentelella:
This project shows:
git clone https://github.com/afourmy/flask-gentelella.git
cd flask-gentelella
pip install -r requirements.txt
(Windows) set FLASK_APP=gentelella.py
(Unix) export FLASK_APP=gentelella.py
(Powershell) $env:FLASK_APP = ".\gentelella.py"
flask run --host=0.0.0.0
sudo apt-get update
sudo apt-get install -y postgresql libpq-dev
sudo -u postgres psql -c "CREATE DATABASE gentelella;"
sudo -u postgres psql -c "CREATE USER gentelella WITH PASSWORD 'your-password';"
sudo -u postgres psql -c "GRANT ALL PRIVILEGES ON DATABASE gentelella TO gentelella;"
export GENTELELLA_CONFIG_MODE=Production
export GENTELELLA_DATABASE_PASSWORD=your-password
docker run -d -p 5000:5000 --name gentelella --restart always afourmy/flask-gentelella
git clone https://github.com/afourmy/flask-gentelella.git
cd flask-gentelella
sudo docker-compose pull && sudo docker-compose build && sudo docker-compose up -d