CindyDelage commited on
Commit
472ab68
·
verified ·
1 Parent(s): 202b9a7

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +4 -1
Dockerfile CHANGED
@@ -17,7 +17,10 @@ COPY --chown=user . /app
17
  #CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860", "--log-level", "debug"]
18
  #!/bin/sh
19
  CMD uvicorn app:app --host 0.0.0.0 --port 7860 --log-level debug & \
20
- sleep 5 && \
 
 
 
21
  curl -X POST "http://localhost:7860/audio" \
22
  -H "Content-Type: application/json" \
23
  -d '{"test_size": 0.2, "test_seed": 42}' && \
 
17
  #CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860", "--log-level", "debug"]
18
  #!/bin/sh
19
  CMD uvicorn app:app --host 0.0.0.0 --port 7860 --log-level debug & \
20
+ until curl -s -o /dev/null "http://localhost:7860"; do \
21
+ echo "En attente du démarrage du serveur..."; \
22
+ sleep 1; \
23
+ done && \
24
  curl -X POST "http://localhost:7860/audio" \
25
  -H "Content-Type: application/json" \
26
  -d '{"test_size": 0.2, "test_seed": 42}' && \