Update Dockerfile
Browse files- Dockerfile +25 -20
Dockerfile
CHANGED
@@ -1,26 +1,31 @@
|
|
1 |
-
#
|
2 |
-
FROM
|
3 |
|
4 |
-
#
|
5 |
-
|
6 |
-
|
7 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
8 |
|
9 |
-
#
|
10 |
-
RUN
|
11 |
-
|
|
|
|
|
|
|
|
|
|
|
12 |
|
13 |
-
#
|
14 |
-
|
15 |
|
16 |
-
# Copy the init.sql file to the container
|
17 |
-
COPY init.sql /docker-entrypoint-initdb.d/
|
18 |
|
19 |
-
|
20 |
-
EXPOSE 5432
|
21 |
|
22 |
-
|
23 |
-
USER postgres
|
24 |
-
|
25 |
-
# Start the PostgreSQL server when the container is launched
|
26 |
-
CMD ["postgres"]
|
|
|
1 |
+
#FROM ubuntu:22.04
|
2 |
+
FROM ubuntu:22.04
|
3 |
|
4 |
+
# Install necessary packages
|
5 |
+
RUN apt-get update && apt-get install -y \
|
6 |
+
curl \
|
7 |
+
wget \
|
8 |
+
unzip \
|
9 |
+
git \
|
10 |
+
python3-pip \
|
11 |
+
libmagic-dev \
|
12 |
+
lsb-release \
|
13 |
+
lsof \
|
14 |
+
postgresql \
|
15 |
|
16 |
+
#NEEDED FOR POSTGRES16
|
17 |
+
RUN curl -fsSL --insecure https://www.postgresql.org/media/keys/ACCC4CF8.asc | gpg --dearmor -o /etc/apt/trusted.gpg.d/postgresql.gpg
|
18 |
+
|
19 |
+
RUN apt-get update && apt-get install -y postgresql-client-16
|
20 |
+
|
21 |
+
|
22 |
+
# Install Python dependencies - FOR
|
23 |
+
RUN pip3 install -r requirements.txt
|
24 |
|
25 |
+
# Expose ports
|
26 |
+
EXPOSE 8501
|
27 |
|
|
|
|
|
28 |
|
29 |
+
WORKDIR postgres
|
|
|
30 |
|
31 |
+
RUN python3 -m streamlit run app.py
|
|
|
|
|
|
|
|