Giter Club home page Giter Club logo

flask-trt's Introduction

Guide

Documentation technique

Vous trouverez la documentation technique à la racine du dépôt Github.

Manuel d'utilisation

Vous trouverez le manuel d'utilisation à la racine du dépôt Github.

Déploiement en local

Avant tout, il faut que Python (3.9+) et PostgreSQL soient installés. Si ce n'est pas déjà fait, vous pouvez les installer sur macOS via Homebrew ou directement depuis les sites officiels respectifs.

Cloner le projet :

git clone https://github.com/JeanDevFR/flask-trt

Se rendre dans le répertoire du projet :

cd flask-trt

Créer un environnement virtuel :

# macOS
python3 -m venv venv

# Windows
py -3 -m venv venv

Activer l'environnement virtuel :

# macOS
. venv/bin/activate

# Windows
venv/Scripts/activate

Installer les packages :

pip install -r requirements.txt

Créer un fichier .env à la racine du répertoire avec les informations suivantes :

SECRET_KEY = "secret"
DATABASE_URL = "postgresql://<username>:<password>@localhost:5432/<db-name>"

Modifier les informations suivantes dans le fichier config.py en fonction du serveur smtp que vous utilisez :

# ...
MAIL_SERVER = 'smtp.gmail.com'
MAIL_PORT = 465 # Ou 587 par exemple
# ...
MAIL_USE_TLS = False
MAIL_USE_SSL = True

Ajouter les variables suivantes dans le fichier .env :

# ...
MAIL_USERNAME = 'username'
MAIL_PASSWORD = 'password'

Créer la base de données :

CREATE DATABASE <db-name>;

Créer les tables :

cd flask-trt
flask db upgrade

Lancer l'application :

flask run

Créer un administrateur :

# Un seul administrateur peut être créé. Conservez-bien son mot de passe.
http://localhost:5000/admin/create/administrator

flask-trt's People

Contributors

jeancastellotti avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.