重写独立dockerfile

This commit is contained in:
2026-05-29 18:19:30 +08:00
parent 823a387118
commit 77bdf56adf
14 changed files with 640 additions and 0 deletions
+14
View File
@@ -0,0 +1,14 @@
FROM gemold-base:latest
COPY src/inventory/ /app/src/inventory/
COPY src/entrypoints/ /app/src/entrypoints/
COPY static/ /app/static/
RUN mkdir -p /app/logs
EXPOSE 8001
HEALTHCHECK --interval=30s --timeout=10s --retries=3 --start-period=30s \
CMD python -c "import urllib.request; urllib.request.urlopen('http://localhost:8001/health')" || exit 1
CMD ["python", "-m", "uvicorn", "entrypoints.inventory:app", "--host", "0.0.0.0", "--port", "8001"]