Update docker workings
Some checks failed
Build and Publish ipserv / build_and_publish (push) Failing after 40s
Some checks failed
Build and Publish ipserv / build_and_publish (push) Failing after 40s
This commit is contained in:
parent
bc13c0dcc2
commit
6b29f7d868
4
.gitignore
vendored
Normal file
4
.gitignore
vendored
Normal file
|
@ -0,0 +1,4 @@
|
|||
.idea/
|
||||
.vscode/
|
||||
.venv/
|
||||
venv/
|
13
Dockerfile
13
Dockerfile
|
@ -1,8 +1,9 @@
|
|||
FROM python:3-slim
|
||||
|
||||
WORKDIR /app
|
||||
COPY ipserv.py /app
|
||||
COPY cert/ /app/cert
|
||||
FROM python:3.12-slim
|
||||
EXPOSE 80/tcp
|
||||
RUN pip install fastapi requests gunicorn uvicorn[standard] aiohttp
|
||||
WORKDIR /app
|
||||
COPY requirements.txt /tmp
|
||||
RUN pip install -r /tmp/requirements.txt
|
||||
COPY cert/ /app/cert
|
||||
COPY ipserv.py /app
|
||||
|
||||
CMD ["gunicorn", "-b", "0.0.0.0:80", "--forwarded-allow-ips", "*", "--worker-class", "uvicorn.workers.UvicornWorker", "ipserv:app"]
|
5
requirements.txt
Normal file
5
requirements.txt
Normal file
|
@ -0,0 +1,5 @@
|
|||
fastapi~=0.110
|
||||
requests~=2.31
|
||||
gunicorn~=22.0.0
|
||||
uvicorn[standard]~=0.29
|
||||
aiohttp~=3.9
|
Reference in a new issue