145 lines
3.6 KiB
YAML
145 lines
3.6 KiB
YAML
services:
|
|
api:
|
|
build: .
|
|
container_name: fastapi-app
|
|
restart: unless-stopped
|
|
environment:
|
|
TZ: ${TZ}
|
|
DATABASE_URL: ${EXTERNAL_DB_URL}
|
|
INTERNAL_API_KEY: ${INTERNAL_API_KEY}
|
|
volumes:
|
|
- ./:/app
|
|
#ports:
|
|
# - "8000:8000"
|
|
depends_on:
|
|
- postgres-dev
|
|
|
|
postgres-dev:
|
|
image: postgres:16
|
|
container_name: local-postgres
|
|
restart: unless-stopped
|
|
environment:
|
|
POSTGRES_USER: ${DEV_PG_USER}
|
|
POSTGRES_PASSWORD: ${DEV_PG_PASSWORD}
|
|
POSTGRES_DB: ${DEV_PG_DB}
|
|
TZ: ${TZ}
|
|
volumes:
|
|
- pgdata:/var/lib/postgresql/data
|
|
#ports:
|
|
# - "5433:5432"
|
|
|
|
php:
|
|
image: php:8.3-fpm
|
|
container_name: php-fpm
|
|
restart: unless-stopped
|
|
working_dir: /var/www/html
|
|
volumes:
|
|
- ./php-app:/var/www/html
|
|
nginx:
|
|
image: nginx:1.27
|
|
container_name: nginx
|
|
restart: unless-stopped
|
|
depends_on:
|
|
- api
|
|
- php
|
|
ports:
|
|
- "80:80"
|
|
volumes:
|
|
- ./nginx.conf:/etc/nginx/nginx.conf:ro
|
|
- ./php-app:/var/www/html:ro
|
|
- ./logs/nginx:/var/log/nginx
|
|
|
|
adminer:
|
|
image: adminer:latest
|
|
container_name: adminer
|
|
restart: unless-stopped
|
|
environment:
|
|
ADMINER_DEFAULT_SERVER: postgres-dev
|
|
#ports:
|
|
# - "8080:8080"
|
|
|
|
redis:
|
|
image: redis:7-alpine
|
|
container_name: redis
|
|
restart: unless-stopped
|
|
command: ["redis-server","--appendonly","yes","--requirepass","${REDIS_PASSWORD}"]
|
|
#ports:
|
|
# - "6379:6379"
|
|
volumes:
|
|
- redisdata:/data
|
|
|
|
# Typebot Services
|
|
typebot-db:
|
|
image: postgres:16
|
|
container_name: typebot-db
|
|
restart: unless-stopped
|
|
environment:
|
|
POSTGRES_DB: typebot
|
|
POSTGRES_USER: typebot
|
|
POSTGRES_PASSWORD: typebot_password
|
|
TZ: ${TZ}
|
|
volumes:
|
|
- typebot_db_data:/var/lib/postgresql/data
|
|
networks:
|
|
- typebot-network
|
|
|
|
typebot-redis:
|
|
image: redis:7-alpine
|
|
container_name: typebot-redis
|
|
restart: unless-stopped
|
|
command: ["redis-server", "--appendonly", "yes", "--requirepass", "typebot_redis_password"]
|
|
volumes:
|
|
- typebot_redis_data:/data
|
|
networks:
|
|
- typebot-network
|
|
|
|
typebot-builder:
|
|
image: baptistearno/typebot-builder:latest
|
|
container_name: typebot-builder
|
|
restart: unless-stopped
|
|
environment:
|
|
- DATABASE_URL=postgresql://typebot:typebot_password@typebot-db:5432/typebot
|
|
- NEXTAUTH_URL=http://localhost:3001
|
|
- NEXTAUTH_SECRET=typebot_builder_secret_key_here_change_this_in_production
|
|
- ENCRYPTION_SECRET=typebot_encryption_secret_key_32_chars_long
|
|
- REDIS_URL=redis://:typebot_redis_password@typebot-redis:6379
|
|
- NEXT_PUBLIC_VIEWER_URL=http://localhost:3000
|
|
- WEBHOOK_URL=http://localhost:3000
|
|
- TELEMETRY_ENABLED=false
|
|
ports:
|
|
- "3001:3000"
|
|
depends_on:
|
|
- typebot-db
|
|
- typebot-redis
|
|
networks:
|
|
- typebot-network
|
|
|
|
typebot-viewer:
|
|
image: baptistearno/typebot-viewer:latest
|
|
container_name: typebot-viewer
|
|
restart: unless-stopped
|
|
environment:
|
|
- DATABASE_URL=postgresql://typebot:typebot_password@typebot-db:5432/typebot
|
|
- NEXTAUTH_URL=http://localhost:3000
|
|
- NEXTAUTH_SECRET=typebot_viewer_secret_key_here_change_this_in_production
|
|
- ENCRYPTION_SECRET=typebot_encryption_secret_key_32_chars_long
|
|
- REDIS_URL=redis://:typebot_redis_password@typebot-redis:6379
|
|
- TELEMETRY_ENABLED=false
|
|
ports:
|
|
- "3000:3000"
|
|
depends_on:
|
|
- typebot-db
|
|
- typebot-redis
|
|
networks:
|
|
- typebot-network
|
|
|
|
volumes:
|
|
pgdata:
|
|
redisdata:
|
|
typebot_db_data:
|
|
typebot_redis_data:
|
|
|
|
networks:
|
|
typebot-network:
|
|
driver: bridge
|