feat: add reminder system with cron scheduler and fix timezone formatting
- Add reminders to Prisma schema (Reminder model, TaskReminder relation) - Add /api/reminders endpoint and cron send-reminders.ts script - Add reminder fields to NewTaskModal and EditTaskModal components - Fix reminder datetime serialization: use toISOString().slice(0,16) for UTC-safe YYYY-MM-DDTHH:mm format compatible with datetime-local inputs - Update Dockerfile to install tsx for cron container - Add AGENTS.md with project conventions - Update docker-compose.yml with cron service and build context
This commit is contained in:
@@ -27,11 +27,29 @@ services:
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
ports:
|
||||
- "3070:3000"
|
||||
- "3000:3000"
|
||||
environment:
|
||||
DATABASE_URL: postgresql://vixtix:vixtix_secret@postgres:5432/vixtix
|
||||
DB_HOST: postgres
|
||||
DB_PORT: 5432
|
||||
|
||||
vixtix-cron:
|
||||
image: vixtix:latest
|
||||
container_name: vixtix-cron
|
||||
restart: unless-stopped
|
||||
depends_on:
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
environment:
|
||||
DATABASE_URL: postgresql://vixtix:vixtix_secret@postgres:5432/vixtix
|
||||
MATTERMOST_WEBHOOK_URL: ${MATTERMOST_WEBHOOK_URL}
|
||||
entrypoint: ["sh", "-c"]
|
||||
command:
|
||||
- |
|
||||
while true; do
|
||||
npx tsx /app/scripts/send-reminders.ts
|
||||
sleep 60
|
||||
done
|
||||
|
||||
volumes:
|
||||
vixtix-data:
|
||||
|
||||
Reference in New Issue
Block a user