use pip-tools for dependecy management, update setup script

This commit is contained in:
mcbloch 2019-04-05 01:25:30 +02:00
parent 3a5f31bfac
commit d33dc05840
4 changed files with 66 additions and 32 deletions

View file

@ -2,15 +2,22 @@
# A simple file to run all instructions from the README # A simple file to run all instructions from the README
## this should be run in the root of the repository ## this should be run in the root of the repository
if [ ! -d "vent" ]; then if [ ! -d "venv" ]; then
echo "No venv found, creating a new one"
python -m venv venv python -m venv venv
fi fi
venv/bin/pip install -r requirements.txt source venv/bin/activate
echo "Downloading dependencies"
pip-sync
echo "Copying config template. All custom config options can be set in the config.py file"
cd app cd app
cp config.example.py config.py cp config.example.py config.py
cp -t . database/*
venv/bin/python create_database.py
rm -f add_* create_database.py
venv/bin/python haldis.py runserver
cd .. cd ..
echo "Seeding database"
./populate-db.sh
echo "You can now run the server with 'python app/haldis.py runserver'"

View file

@ -2,5 +2,5 @@
cd app cd app
cp database/* . cp database/* .
../venv/bin/python create_database.py python create_database.py
rm -f add_* create_database.py muhscheme rm -f add_* create_database.py muhscheme

12
requirements.in Normal file
View file

@ -0,0 +1,12 @@
Flask
Flask-Login
Flask-Bootstrap
Flask-SQLAlchemy
Flask-DebugToolbar
airbrake
Flask-WTF
Flask-OAuthlib
Flask-Admin
Flask-Migrate
Flask-Script
pip-tools

View file

@ -1,25 +1,40 @@
Flask==0.12 #
Flask-Admin==1.4.2 # This file is autogenerated by pip-compile
Flask-Bootstrap==3.3.7.1 # To update, run:
Flask-DebugToolbar==0.10.0 #
Flask-Login==0.4.0 # pip-compile
Flask-Migrate==2.0.3 #
Flask-OAuthlib==0.9.3 airbrake==2.1.2
Flask-SQLAlchemy==2.1 alembic==1.0.8 # via flask-migrate
Flask-Script==2.0.5 blinker==1.4 # via flask-debugtoolbar
Flask-WTF==0.14.2 certifi==2019.3.9 # via requests
Jinja2==2.9.5 chardet==3.0.4 # via requests
Mako==1.0.6 click==7.0 # via flask, pip-tools
MarkupSafe==0.23 dominate==2.3.5 # via flask-bootstrap
PyMySQL==0.7.9 flask-admin==1.5.3
SQLAlchemy==1.1.5 flask-bootstrap==3.3.7.1
WTForms==2.1 flask-debugtoolbar==0.10.1
Werkzeug==0.11.15 flask-login==0.4.1
airbrake==1.3.3 flask-migrate==2.4.0
alembic==0.8.10 flask-oauthlib==0.9.5
blinker==1.4 flask-script==2.0.6
itsdangerous==0.24 flask-sqlalchemy==2.3.2
oauthlib==2.0.1 flask-wtf==0.14.2
requests==2.13.0 flask==1.0.2
requests-oauthlib==0.7.0 idna==2.8 # via requests
six==1.10.0 itsdangerous==1.1.0 # via flask, flask-debugtoolbar
jinja2==2.10 # via flask
mako==1.0.8 # via alembic
markupsafe==1.1.1 # via jinja2, mako
oauthlib==2.1.0 # via flask-oauthlib, requests-oauthlib
pip-tools==3.6.0
python-dateutil==2.8.0 # via alembic
python-editor==1.0.4 # via alembic
requests-oauthlib==1.1.0 # via flask-oauthlib
requests==2.21.0 # via airbrake, requests-oauthlib
six==1.12.0 # via pip-tools, python-dateutil
sqlalchemy==1.3.2 # via alembic, flask-sqlalchemy
urllib3==1.24.1 # via requests
visitor==0.1.3 # via flask-bootstrap
werkzeug==0.15.2 # via flask, flask-debugtoolbar
wtforms==2.2.1 # via flask-admin, flask-wtf