Compare commits

..

2 Commits

Author SHA1 Message Date
15e68b88e8 adds uwsgi support instead of using flask dev server
- uses existing wsgi.py file

- adds wsgi.ini file
  - sets socket
  - defines application to be run, which it gets from wsgi.py file
  - uses http communication to nginx server
  - some random number of workers

- updates Dockerfile and docker-entrypoint
2020-07-10 11:47:49 +02:00
adb20dea14 code cleanup and comments 2020-07-10 10:55:01 +02:00
5 changed files with 14 additions and 13 deletions

BIN
app.db

Binary file not shown.

View File

@@ -1,7 +1,5 @@
#!/bin/sh
cd /home/calendarwatch
# uwsgi --http-socket 0.0.0.0:8084 -w wsgi --protocol=https
export FLASK_APP=/home/calendarwatch/server.py
python3 server.py
uwsgi --ini wsgi.ini
echo "server has been started"

View File

@@ -1,10 +0,0 @@
{
"latestVersion": "1.0",
"latestVersionCode": 1,
"url": "https://longitudecalendar.com/static/res/daria-scan-1.0.apk",
"releaseNotes": [
"- First evolution",
"- Second evolution",
"- Bug fixes"
]
}

Binary file not shown.

13
wsgi.ini Normal file
View File

@@ -0,0 +1,13 @@
# uwsgi --socket 0.0.0.0:8084 -w wsgi:application --protocol=http
[uwsgi]
module = wsgi:application
protocol = http
master = true
processes = 5
socket = 0.0.0.0:8084
die-on-term = true