Spaces:
Runtime error
Runtime error
Commit
·
58661f4
1
Parent(s):
ec779ba
update dockerfile
Browse files- Dockerfile +2 -5
- load_data.py +0 -1
Dockerfile
CHANGED
@@ -1,4 +1,4 @@
|
|
1 |
-
FROM
|
2 |
|
3 |
# Exposing ports
|
4 |
EXPOSE 6900
|
@@ -12,15 +12,12 @@ COPY *.whl /packages/
|
|
12 |
|
13 |
# Copy users db file along with execution script
|
14 |
COPY start.sh /
|
15 |
-
#COPY start_test.sh /
|
16 |
COPY load_data.py /
|
17 |
COPY users.yml /packages/
|
18 |
|
19 |
# Install packages
|
20 |
RUN apt update
|
21 |
-
RUN apt -y install
|
22 |
-
RUN curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
|
23 |
-
RUN python3.9 get-pip.py
|
24 |
|
25 |
# Create new user for starting elasticsearch
|
26 |
RUN useradd -ms /bin/bash user -p "$(openssl passwd -1 ubuntu)"
|
|
|
1 |
+
FROM python:3.9-slim
|
2 |
|
3 |
# Exposing ports
|
4 |
EXPOSE 6900
|
|
|
12 |
|
13 |
# Copy users db file along with execution script
|
14 |
COPY start.sh /
|
|
|
15 |
COPY load_data.py /
|
16 |
COPY users.yml /packages/
|
17 |
|
18 |
# Install packages
|
19 |
RUN apt update
|
20 |
+
RUN apt -y install python3.9-dev gcc gnupg apache2-utils systemctl curl sudo vim
|
|
|
|
|
21 |
|
22 |
# Create new user for starting elasticsearch
|
23 |
RUN useradd -ms /bin/bash user -p "$(openssl passwd -1 ubuntu)"
|
load_data.py
CHANGED
@@ -102,7 +102,6 @@ def load_datasets():
|
|
102 |
|
103 |
|
104 |
while True:
|
105 |
-
api_key = os.getenv("API_KEY")
|
106 |
try:
|
107 |
response = requests.get("http://0.0.0.0:6900/")
|
108 |
if response.status_code == 200:
|
|
|
102 |
|
103 |
|
104 |
while True:
|
|
|
105 |
try:
|
106 |
response = requests.get("http://0.0.0.0:6900/")
|
107 |
if response.status_code == 200:
|