63 lines
1.6 KiB
YAML
63 lines
1.6 KiB
YAML
services:
|
|
postgres:
|
|
image: pgvector/pgvector:pg15
|
|
container_name: formbricks-db
|
|
environment:
|
|
POSTGRES_USER: postgres
|
|
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
|
|
POSTGRES_DB: formbricks
|
|
volumes:
|
|
- postgres-data:/var/lib/postgresql/data
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "psql -U postgres -d formbricks -c 'SELECT 1' > /dev/null 2>&1"]
|
|
interval: 5s
|
|
timeout: 5s
|
|
retries: 10
|
|
start_period: 10s
|
|
restart: unless-stopped
|
|
|
|
redis:
|
|
image: redis:7-alpine
|
|
container_name: formbricks-redis
|
|
volumes:
|
|
- redis-data:/data
|
|
healthcheck:
|
|
test: ["CMD", "redis-cli", "ping"]
|
|
interval: 5s
|
|
timeout: 5s
|
|
retries: 5
|
|
restart: unless-stopped
|
|
|
|
formbricks:
|
|
image: ghcr.io/formbricks/formbricks:latest
|
|
container_name: formbricks-app
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
redis:
|
|
condition: service_healthy
|
|
ports:
|
|
- ${PORT}:3000
|
|
environment:
|
|
WEBAPP_URL: ${WEBAPP_URL}
|
|
DATABASE_URL: postgresql://postgres:${POSTGRES_PASSWORD}@postgres:5432/formbricks?schema=public
|
|
NEXTAUTH_SECRET: ${NEXTAUTH_SECRET}
|
|
NEXTAUTH_URL: ${WEBAPP_URL}
|
|
ENCRYPTION_KEY: ${ENCRYPTION_KEY}
|
|
REDIS_URL: redis://redis:6379
|
|
volumes:
|
|
- uploads:/home/nextjs/apps/web/uploads
|
|
- saml:/home/nextjs/apps/web/saml-connection
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "wget -qO- http://localhost:3000/health || exit 1"]
|
|
interval: 30s
|
|
timeout: 10s
|
|
retries: 3
|
|
start_period: 60s
|
|
restart: unless-stopped
|
|
|
|
volumes:
|
|
postgres-data:
|
|
redis-data:
|
|
uploads:
|
|
saml: |