Spaces:
Build error
Build error
Rename Dockerfile.sql to Dockerfile
Browse files- Dockerfile +11 -0
- Dockerfile.sql +0 -38
Dockerfile
ADDED
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
FROM python:3.9
|
2 |
+
|
3 |
+
WORKDIR /code
|
4 |
+
|
5 |
+
COPY ./requirements.txt /code/requirements.txt
|
6 |
+
|
7 |
+
RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
|
8 |
+
|
9 |
+
COPY . .
|
10 |
+
|
11 |
+
CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "7860"]
|
Dockerfile.sql
DELETED
@@ -1,38 +0,0 @@
|
|
1 |
-
FROM python:3.9-slim
|
2 |
-
|
3 |
-
ENV PYTHONUNBUFFERED=1 \
|
4 |
-
PYTHONDONTWRITEBYTECODE=1 \
|
5 |
-
PIP_NO_CACHE_DIR=1 \
|
6 |
-
PIP_DISABLE_PIP_VERSION_CHECK=1 \
|
7 |
-
PIP_DEFAULT_TIMEOUT=120 \
|
8 |
-
LC_ALL=C.UTF-8 \
|
9 |
-
LANG=C.UTF-8
|
10 |
-
|
11 |
-
# we probably need build tools?
|
12 |
-
RUN apt-get update \
|
13 |
-
&& apt-get install --yes --no-install-recommends \
|
14 |
-
gcc \
|
15 |
-
g++ \
|
16 |
-
build-essential \
|
17 |
-
python3-dev
|
18 |
-
|
19 |
-
WORKDIR /app
|
20 |
-
|
21 |
-
# if we have a packages.txt, install it
|
22 |
-
COPY packages.txt packages.txt
|
23 |
-
RUN xargs -a packages.txt apt-get install --yes
|
24 |
-
|
25 |
-
COPY requirements.txt requirements.txt
|
26 |
-
RUN pip install --no-cache-dir --upgrade -r requirements.txt
|
27 |
-
|
28 |
-
EXPOSE 8501
|
29 |
-
|
30 |
-
COPY . .
|
31 |
-
|
32 |
-
CMD ["streamlit", "run", "streamlit_app.py"]
|
33 |
-
|
34 |
-
# docker build --progress=plain --tag selenium:latest .
|
35 |
-
# docker run -ti -p 8501:8501 --rm selenium:latest /bin/bash
|
36 |
-
# docker run -ti -p 8501:8501 --rm selenium:latest
|
37 |
-
# docker run -ti -p 8501:8501 -v ${pwd}:/app --rm selenium:latest
|
38 |
-
# docker run -ti -p 8501:8501 -v ${pwd}:/app --rm selenium:latest /bin/bash
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|