Skip to content

Commit 6087a03

Browse files
committed
deploy with proper wsgi
1 parent ef9cd4c commit 6087a03

4 files changed

Lines changed: 7 additions & 6 deletions

File tree

Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@ COPY requirements.txt /app/requirements.txt
44
RUN pip install -r /app/requirements.txt
55
COPY . /app
66
WORKDIR /app
7-
ENTRYPOINT ["python"]
8-
CMD ["GazelleUI.py"]
7+
ENTRYPOINT ["gunicorn"]
8+
CMD ["-b", "0.0.0.0:2020", "--workers", "1", "wsgi:app"]

lib/jobs.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,19 @@ def job_list():
66
return [
77
{
88
'id': 'torrents',
9-
'func': '__main__:jobs.download_torrents',
9+
'func': 'lib.jobs:download_torrents',
1010
'trigger': 'interval',
1111
'seconds': 10
1212
},
1313
{
1414
'id': 'update_user_info',
15-
'func': '__main__:jobs.update_user',
15+
'func': 'lib.jobs:update_user',
1616
'trigger': 'interval',
1717
'seconds': 900
1818
},
1919
{
2020
'id': 'autofetch',
21-
'func': '__main__:jobs.autofetch',
21+
'func': 'lib.jobs:autofetch',
2222
'trigger': 'interval',
2323
'seconds': 11520
2424
}

requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@ funcsigs
33
futures
44
flask
55
flask_apscheduler
6+
gunicorn

wsgi.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
from WhatUI import app
1+
from GazelleUI import app
22

33
if __name__ == "__main__":
44
app.run()

0 commit comments

Comments
 (0)