Transférer les fichiers vers ''
This commit is contained in:
parent
6562d1302f
commit
bdf8c446ea
|
@ -0,0 +1,25 @@
|
|||
Packages:
|
||||
python3
|
||||
virtualenv
|
||||
on Virtual environment
|
||||
python-dotenv
|
||||
flask
|
||||
flask-wtf
|
||||
flask-sqlalchemy
|
||||
flask-migrate
|
||||
|
||||
- - How to install your 'Pycloud' with development environment:
|
||||
- Install python3 (need python3 in PATH, you can download Python on the Website and check the 'add to PATH') and virtualenv ('pip3 install virtualenv').
|
||||
- Make sure you have Python on your PATH (Open a terminal and type 'python', if the version is Python 2.x, try 'python3').
|
||||
- Create your cloud directory and enter in it.
|
||||
- Create a virtual environment ('python -m venv venv' or 'python3 -m venv venv').
|
||||
- Set your virtual environment ('virtualenv venv').
|
||||
- Activate it (Windows: 'venv\Script\activate', others: 'venv/bin/activate').
|
||||
- Download all others packages ('pip3 install package-name').
|
||||
- Paste 'Pycloud' project on the directory.
|
||||
- Create a '.flaskenv' file and write it:
|
||||
FLASK_APP=Pycloud.py
|
||||
FLASK_ENV=development
|
||||
- Initialize your Data Base ('flask db init')
|
||||
- Start Pycloud ('flask run').
|
||||
- You've done!
|
|
@ -0,0 +1,8 @@
|
|||
import os
|
||||
|
||||
class Config(object):
|
||||
SECRET_KEY = os.environ.get('SECRET_KEY') or 'you-will-never-guess'
|
||||
APPLICATION_DIR = os.path.dirname(os.path.realpath(__file__))
|
||||
FILES_DIR = os.path.join(APPLICATION_DIR, 'Files')
|
||||
SQLALCHEMY_DATABASE_URI = os.environ.get('DATABASE_URL') or 'sqlite:///' + os.path.join(APPLICATION_DIR, 'app.db')
|
||||
SQLALCHEMY_TRACK_MODIFICATIONS = False
|
Loading…
Reference in New Issue