-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdashboard.Dockerfile
30 lines (23 loc) · 977 Bytes
/
dashboard.Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
FROM python:3.9-slim
WORKDIR /app
# copy the dashboard folder to the /app directory
COPY dashboard .
# requiremenets.txt file #
COPY dashboard/dashboard_requirements.txt /app/dashboard_requirements.txt
# secrets file #
COPY secrets/cryptopulse-secret.json /app/secrets/cryptopulse-secret.json
# secrets file
RUN apt-get update && apt-get install -y \
build-essential \
curl \
software-properties-common \
&& rm -rf /var/lib/apt/lists/*
# expose port for the dashboard
EXPOSE 8500
# upgrade pip & install the required packages for the dashboard
RUN pip install --upgrade pip && \
pip install --default-timeout=1000 --verbose -r /app/dashboard_requirements.txt
# environment variables for the secrets file
ENV GOOGLE_APPLICATION_CREDENTIALS=/app/secrets/cryptopulse-secret.json
# entrypoint for the dashboard
ENTRYPOINT [ "streamlit", "run", "/app/dashboard_app.py", "--server.port", "8500", "--server.headless", "True", "server.address", "0.0.0.0" ]