Served by uWSGI
This commit is contained in:
18
Dockerfile
18
Dockerfile
@@ -1,21 +1,21 @@
|
|||||||
# start by pulling the python image
|
# start by pulling the python image
|
||||||
FROM python:3.8-alpine
|
FROM python:3
|
||||||
|
|
||||||
|
# install uwsgi
|
||||||
|
RUN apt install -y gcc && pip3 install uwsgi
|
||||||
|
|
||||||
# copy the requirements file into the image
|
# copy the requirements file into the image
|
||||||
COPY ./requirements.txt /app/requirements.txt
|
COPY ./requirements.txt /tmp/requirements.txt
|
||||||
|
RUN pip3 install --no-cache-dir -r /tmp/requirements.txt
|
||||||
|
|
||||||
# switch working directory
|
# switch working directory
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|
||||||
# install the dependencies and packages in the requirements file
|
|
||||||
RUN pip install -r requirements.txt
|
|
||||||
|
|
||||||
# copy every content from the local file to the image
|
# copy every content from the local file to the image
|
||||||
COPY ./app.py /app
|
COPY ./app.py /app
|
||||||
COPY ./templates/index.html /app/templates/index.html
|
COPY ./templates/index.html /app/templates/index.html
|
||||||
COPY ./static/favicon.ico /app/static/favicon.ico
|
COPY ./static/favicon.ico /app/static/favicon.ico
|
||||||
|
COPY ./app.ini /app
|
||||||
|
COPY ./wsgi.py /app
|
||||||
|
|
||||||
# configure the container to run in an executed manner
|
CMD ["uwsgi","--ini","app.ini"]
|
||||||
ENTRYPOINT [ "python" ]
|
|
||||||
|
|
||||||
CMD ["app.py" ]
|
|
BIN
__pycache__/app.cpython-310.pyc
Normal file
BIN
__pycache__/app.cpython-310.pyc
Normal file
Binary file not shown.
5
app.ini
Normal file
5
app.ini
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
[uwsgi]
|
||||||
|
wsgi-file = wsgi.py
|
||||||
|
master = 5
|
||||||
|
http = :90
|
||||||
|
die-on-term = true
|
@@ -1,3 +1,16 @@
|
|||||||
|
blinker==1.8.2
|
||||||
|
certifi==2024.2.2
|
||||||
|
charset-normalizer==3.3.2
|
||||||
|
click==8.1.7
|
||||||
|
colorama==0.4.6
|
||||||
|
dominate==2.9.1
|
||||||
Flask==3.0.3
|
Flask==3.0.3
|
||||||
Flask-Bootstrap==3.3.7.1
|
Flask-Bootstrap==3.3.7.1
|
||||||
|
idna==3.7
|
||||||
|
itsdangerous==2.2.0
|
||||||
|
Jinja2==3.1.4
|
||||||
|
MarkupSafe==2.1.5
|
||||||
requests==2.32.2
|
requests==2.32.2
|
||||||
|
urllib3==2.2.1
|
||||||
|
visitor==0.1.3
|
||||||
|
Werkzeug==3.0.3
|
||||||
|
Reference in New Issue
Block a user