CI / test-and-package (push) Successful in 37s
- ntfy.py: send_meal_reminder() with Home/Out HTTP action buttons, test helper - models.py: new columns ntfy_url, ntfy_token, callback_token on users table - meals.py: /api/ntfy-callback (public, token-authenticated), /ntfy-settings, /ntfy-test - app.py: flask send-reminders CLI command (cron-schedulable) - Dashboard: ntfy config form in Account Settings - i18n: translations for all ntfy strings (en/fr/de) - Dockerfile: include ntfy.py in COPY - tests: 15 new tests covering callback, settings, and auth - docs: updated AGENTS.md and doc/index.md
25 lines
602 B
Docker
25 lines
602 B
Docker
FROM python:3.13-alpine
|
|
|
|
WORKDIR /app
|
|
|
|
# Install dependencies
|
|
COPY requirements.txt .
|
|
RUN pip install --no-cache-dir -r requirements.txt
|
|
|
|
# Copy application
|
|
COPY app.py models.py auth.py meals.py i18n.py ntfy.py ./
|
|
COPY templates/ templates/
|
|
COPY static/ static/
|
|
|
|
# Create persistent data directory
|
|
RUN mkdir -p /data
|
|
ENV DB_PATH=/data/meals.db
|
|
|
|
EXPOSE 5000
|
|
|
|
# Generate a default secret key at build time (override in prod)
|
|
ENV SECRET_KEY=change-me-in-production
|
|
|
|
# Run in production mode (no debug, use a WSGI server)
|
|
CMD ["flask", "--app", "app:create_app()", "run", "--host=0.0.0.0", "--port=5000"]
|