Spaces:
Build error
Build error
JCai commited on
Commit ·
9e348a3
1
Parent(s): c93dd01
add Dockerfile
Browse files- Dockerfile +19 -0
Dockerfile
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
FROM python:3.10-slim
|
| 2 |
+
|
| 3 |
+
WORKDIR /opt/app
|
| 4 |
+
COPY . .
|
| 5 |
+
RUN pip install --no-cache-dir -r /opt/app/requirements.txt
|
| 6 |
+
|
| 7 |
+
# Install packages that we need. vim is for helping with debugging
|
| 8 |
+
ENV DEBIAN_FRONTEND noninteractive
|
| 9 |
+
RUN apt-get update && \
|
| 10 |
+
apt-get upgrade -yq ca-certificates && \
|
| 11 |
+
apt-get install -yq --no-install-recommends \
|
| 12 |
+
prometheus-node-exporter
|
| 13 |
+
|
| 14 |
+
EXPOSE 7860
|
| 15 |
+
EXPOSE 8000
|
| 16 |
+
EXPOSE 9100
|
| 17 |
+
ENV GRADIO_SERVER_NAME "0.0.0.0"
|
| 18 |
+
|
| 19 |
+
CMD bash -c "prometheus-node-exporter --web.listen-address=':9100' & python /opt/app/app.py"
|