Update Dockerfile

This commit is contained in:
saidsurucu
2025-06-29 20:40:59 +03:00
parent 3746804b20
commit e34bbdc355
+1 -5
View File
@@ -21,11 +21,7 @@ ENV PORT=8000
# -------- Health check ----------------------------------------------------- # -------- Health check -----------------------------------------------------
HEALTHCHECK --interval=30s --timeout=10s --start-period=10s --retries=3 \ HEALTHCHECK --interval=30s --timeout=10s --start-period=10s --retries=3 \
CMD python - <<'PY' CMD python -c "import httpx, os, sys; r=httpx.get(f'http://localhost:{os.getenv(\"PORT\",\"8000\")}/health'); sys.exit(0 if r.status_code==200 else 1)"
import httpx, os, sys; \
r=httpx.get(f"http://localhost:{os.getenv('PORT','8000')}/health"); \
sys.exit(0 if r.status_code==200 else 1)
PY
EXPOSE 8000 EXPOSE 8000