feat: add Docker support for push notifications
- Update docker-compose.yml to include VAPID environment variables - Create DOCKER_PUSH_NOTIFICATIONS_SETUP.md with Docker-specific instructions - Create PUSH_NOTIFICATIONS_DOCKER_CHECKLIST.md for easy setup tracking - Update .env.example with Docker command for generating VAPID keys Setup for Docker: 1. Generate VAPID keys (npx web-push generate-vapid-keys) 2. Add keys to .env file 3. Run: docker-compose exec app npx prisma db push 4. Rebuild: docker-compose up --build The web-push package is automatically installed during docker build. All notification functionality works the same in Docker as locally.
This commit is contained in:
@@ -13,6 +13,10 @@ services:
|
||||
- NEXTAUTH_SECRET=${NEXTAUTH_SECRET}
|
||||
- AUTH_SECRET=${AUTH_SECRET}
|
||||
- AUTH_TRUST_HOST=true
|
||||
# Push Notifications (VAPID)
|
||||
- VAPID_PUBLIC_KEY=${VAPID_PUBLIC_KEY}
|
||||
- VAPID_PRIVATE_KEY=${VAPID_PRIVATE_KEY}
|
||||
- VAPID_SUBJECT=${VAPID_SUBJECT}
|
||||
restart: unless-stopped
|
||||
depends_on:
|
||||
- db-check
|
||||
|
||||
Reference in New Issue
Block a user