| FROM python:3.12-slim | |
| WORKDIR /app | |
| RUN pip install --no-cache-dir aiohttp | |
| COPY core.py . | |
| COPY hot_reload.py . | |
| COPY sandbox.sh . | |
| COPY static/ static/ | |
| RUN chmod +x sandbox.sh | |
| EXPOSE 8765 | |
| HEALTHCHECK --interval=30s --timeout=10s --start-period=5s --retries=3 \ | |
| CMD python -c "import urllib.request; urllib.request.urlopen('http://localhost:8765/api/health')" || exit 1 | |
| CMD ["python", "core.py"] | |