Fixed docker

This commit is contained in:
Dmitriy Shishkov 2021-07-02 05:21:06 +05:00
parent ea89cf6dde
commit 7812242f8c
No known key found for this signature in database
GPG Key ID: 14358F96FCDD8060
2 changed files with 7 additions and 4 deletions

3
.dockerignore Normal file
View File

@ -0,0 +1,3 @@
.venv
__pycache__/
.vscode

View File

@ -1,13 +1,13 @@
FROM python FROM python
WORKDIR /app WORKDIR /srv
COPY ./requirements.txt /app/requirements.txt COPY ./requirements.txt /srv/requirements.txt
RUN pip install -r requirements.txt RUN pip install -r requirements.txt
EXPOSE 80 EXPOSE 80
COPY ./app /app COPY ./app /srv/app
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "80"] CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "80"]