Spaces:
Runtime error
Runtime error
TahaRasouli
commited on
Commit
•
e0c9b96
1
Parent(s):
214240f
Create Dockerfile
Browse files- Dockerfile +13 -0
Dockerfile
ADDED
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
FROM python:3.9-slim
|
2 |
+
WORKDIR /app
|
3 |
+
COPY requirements.txt ./requirements.txt
|
4 |
+
RUN apt-get update \
|
5 |
+
&& apt-get -y install libpq-dev gcc \
|
6 |
+
&& pip install psycopg2
|
7 |
+
# Install uvicorn
|
8 |
+
RUN pip install uvicorn
|
9 |
+
# Install dependencies
|
10 |
+
RUN pip install -r requirements.txt
|
11 |
+
COPY . /app
|
12 |
+
ENTRYPOINT ["uvicorn", "main:app"]
|
13 |
+
CMD ["--host", "0.0.0.0", "--port", "7860"]
|