0xarchit commited on
Commit
5f321cb
·
1 Parent(s): 6848116

fix entrypoint

Browse files
Files changed (1) hide show
  1. entrypoint.sh +12 -7
entrypoint.sh CHANGED
@@ -1,16 +1,21 @@
1
  #!/bin/bash
2
 
3
- # Start Ingest Service (Go)
 
 
 
4
  /app/ingest-service/ingest-service &
5
 
6
- # Start ML Service in its own subshell
 
7
  (
8
- cd /app/ml-service
9
- export PYTHONPATH=.
10
- /opt/ml_venv/bin/python -m app.main
11
  ) &
12
 
13
- # Start Control Plane
 
14
  cd /app/control-plane
15
- export PYTHONPATH=.
16
  exec /opt/cp_venv/bin/python -m uvicorn app.main:app --host 0.0.0.0 --port 7860
 
1
  #!/bin/bash
2
 
3
+ # Clear any previous Python paths
4
+ unset PYTHONPATH
5
+
6
+ # 1. Start Ingest Service (Go)
7
  /app/ingest-service/ingest-service &
8
 
9
+ # 2. Start ML Service (Python)
10
+ # We run this in a subshell ( ... ) to keep its paths isolated
11
  (
12
+ cd /app/ml-service
13
+ export PYTHONPATH=/app/ml-service
14
+ /opt/ml_venv/bin/python -m app.main
15
  ) &
16
 
17
+ # 3. Start Control Plane (Python)
18
+ # This is the main process that stays in the foreground
19
  cd /app/control-plane
20
+ export PYTHONPATH=/app/control-plane
21
  exec /opt/cp_venv/bin/python -m uvicorn app.main:app --host 0.0.0.0 --port 7860