app updated to be served as a waitress backend service
This commit is contained in:
@@ -1,23 +1,30 @@
|
||||
to install the dev env:
|
||||
FLowers
|
||||
-------
|
||||
|
||||
The current code base is designed to run undert a waitress server as a backend to apache
|
||||
The app should be called as http:// ... /flowers (so as a subfolder of the domain)
|
||||
|
||||
to install the env:
|
||||
python3 -m venv venv
|
||||
source venv/bin/activate
|
||||
pip install flask waitress fernet pymysql pytz
|
||||
|
||||
|
||||
sudo pip3 install virtualenv
|
||||
virtualenv p3env
|
||||
source p3env/bin/activate
|
||||
pip install uwsgi flask fernet pymysql
|
||||
install apache and activate proxy:
|
||||
a2enmod proxy
|
||||
a2enmod proxy_http
|
||||
|
||||
and put the following in the site...conf file:
|
||||
ProxyPass "/flowers" "http://127.0.0.1:5012/flowers"
|
||||
ProxyPassReverse "/flowers" "http://127.0.0.1:5012/flowers"
|
||||
|
||||
to install kivi in the venv:
|
||||
pip install Cython==0.23
|
||||
sudo apt-get install libgl1-mesa-dev
|
||||
pip install kivy
|
||||
pip install pygame
|
||||
vi ~/.kivy/config.ini
|
||||
change: multisamples = 0
|
||||
|
||||
|
||||
# as root in mysql
|
||||
create database Flowers;
|
||||
grant create,select,update,insert,grant option on Flowers.* to flower@localhost identified by '608f0b988db4a96066af7dd8870de96c';
|
||||
grant create user,reload on *.* to flower@localhost;
|
||||
flush privileges;
|
||||
flush privileges;
|
||||
|
||||
start waitress:
|
||||
waitress-serve --threads=6 --host=127.0.0.1 --port=5012 --call flowers:create_app
|
||||
Reference in New Issue
Block a user