Spaces:
Running
Running
MVPilgrim
commited on
Commit
·
b3ee4e7
1
Parent(s):
a641b1d
debug
Browse files- Dockerfile +2 -2
- app.py +1 -1
- cmd.sh +4 -0
- startup.sh +2 -2
Dockerfile
CHANGED
@@ -22,8 +22,8 @@ COPY ./semsearchDbgUI.py /app/semsearchDbgUI.py
|
|
22 |
COPY ./startupDbgUI.sh /app/startupDbgUI.sh
|
23 |
COPY ./.streamlit/main.css /app/.streamlit/main.css
|
24 |
COPY ./app.py /app/app.py
|
25 |
-
COPY ./
|
26 |
-
RUN chmod 755 /app/startup.sh /app/
|
27 |
|
28 |
COPY ./multi-qa-MiniLM-L6-cos-v1 /app/multi-qa-MiniLM-L6-cos-v1
|
29 |
|
|
|
22 |
COPY ./startupDbgUI.sh /app/startupDbgUI.sh
|
23 |
COPY ./.streamlit/main.css /app/.streamlit/main.css
|
24 |
COPY ./app.py /app/app.py
|
25 |
+
COPY ./cmd.sh /app/cmd.sh
|
26 |
+
RUN chmod 755 /app/startup.sh /app/cmd.sh
|
27 |
|
28 |
COPY ./multi-qa-MiniLM-L6-cos-v1 /app/multi-qa-MiniLM-L6-cos-v1
|
29 |
|
app.py
CHANGED
@@ -52,7 +52,7 @@ try:
|
|
52 |
subprocess.Popen(["/app/startup.sh"])
|
53 |
# Wait for text2vec-transformers and Weaviate DB to initialize.
|
54 |
time.sleep(180)
|
55 |
-
subprocess.run(["/
|
56 |
except Exception as e:
|
57 |
emsg = str(e)
|
58 |
logger.error(f"### subprocess.run EXCEPTION. e: {emsg}")
|
|
|
52 |
subprocess.Popen(["/app/startup.sh"])
|
53 |
# Wait for text2vec-transformers and Weaviate DB to initialize.
|
54 |
time.sleep(180)
|
55 |
+
subprocess.run(["/app/cmd.sh 'ps -ef'"])
|
56 |
except Exception as e:
|
57 |
emsg = str(e)
|
58 |
logger.error(f"### subprocess.run EXCEPTION. e: {emsg}")
|
cmd.sh
ADDED
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
1 |
+
#! /bin/bash
|
2 |
+
|
3 |
+
echo "### executing command parameter $1"
|
4 |
+
eval "$1"
|
startup.sh
CHANGED
@@ -8,7 +8,7 @@
|
|
8 |
exec &> /app/startup.log
|
9 |
|
10 |
echo "#### startup.sh entered."
|
11 |
-
ps -ef
|
12 |
|
13 |
# Is startup.sh already running?
|
14 |
cnt=$(ps -ef | grep -i startup.sh | wc -l)
|
@@ -49,7 +49,7 @@ echo "### After Weaviate DB start. RC=$?"
|
|
49 |
#sleep 120
|
50 |
|
51 |
echo "### Before sleep 120 then wait."
|
52 |
-
ps -ef
|
53 |
wait
|
54 |
|
55 |
|
|
|
8 |
exec &> /app/startup.log
|
9 |
|
10 |
echo "#### startup.sh entered."
|
11 |
+
echo "### ps -ef 1"; ps -ef
|
12 |
|
13 |
# Is startup.sh already running?
|
14 |
cnt=$(ps -ef | grep -i startup.sh | wc -l)
|
|
|
49 |
#sleep 120
|
50 |
|
51 |
echo "### Before sleep 120 then wait."
|
52 |
+
echo "### ps -ef 2: "; ps -ef
|
53 |
wait
|
54 |
|
55 |
|