askrobots / dbbasic-examples
Public
Example DBBasic apps (an API, a blog and a microblog) and a template for new DBBasic modules.
danq9
Add official module template for creating DBBasic packages
17cf88a
1 year, 1 month ago
History
Dockerfile · 443 bytes · 19 lines
| 1 | FROM python:3.12-slim |
| 2 | |
| 3 | WORKDIR /app |
| 4 | |
| 5 | COPY requirements.txt . |
| 6 | RUN pip install --no-cache-dir -r requirements.txt |
| 7 | |
| 8 | COPY . . |
| 9 | |
| 10 | # Create data directories |
| 11 | RUN mkdir -p data etc var |
| 12 | |
| 13 | # Health check using Python (no curl/wget needed) |
| 14 | HEALTHCHECK --interval=30s --timeout=10s --start-period=120s --retries=3 \ |
| 15 | CMD python3 healthcheck.py |
| 16 | |
| 17 | EXPOSE 3000 |
| 18 | |
| 19 | CMD ["uvicorn", "dbbasic_web.asgi:app", "--host", "0.0.0.0", "--port", "3000", "--workers", "2"] |