119 lines
2.8 KiB
YAML
119 lines
2.8 KiB
YAML
version: '3.8'
|
|
|
|
services:
|
|
postgres:
|
|
image: postgres:15-alpine
|
|
container_name: netbird-postgres
|
|
environment:
|
|
POSTGRES_DB: netbird
|
|
POSTGRES_USER: netbird
|
|
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-netbird123}
|
|
volumes:
|
|
- postgres_data:/var/lib/postgresql/data
|
|
ports:
|
|
- "5432:5432"
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "pg_isready -U netbird"]
|
|
interval: 10s
|
|
timeout: 5s
|
|
retries: 5
|
|
|
|
redis:
|
|
image: redis:7-alpine
|
|
container_name: netbird-redis
|
|
ports:
|
|
- "6379:6379"
|
|
volumes:
|
|
- redis_data:/data
|
|
healthcheck:
|
|
test: ["CMD", "redis-cli", "ping"]
|
|
interval: 10s
|
|
timeout: 5s
|
|
retries: 5
|
|
|
|
management:
|
|
image: netbirdio/management:0.70.5
|
|
container_name: netbird-management
|
|
depends_on:
|
|
postgres:
|
|
condition: service_healthy
|
|
redis:
|
|
condition: service_healthy
|
|
environment:
|
|
# PostgreSQL configuration
|
|
NETBIRD_MGMT_DATASTORE: postgres
|
|
NETBIRD_MGMT_DATASTORE_HOST: postgres
|
|
NETBIRD_MGMT_DATASTORE_PORT: "5432"
|
|
NETBIRD_MGMT_DATASTORE_DB: netbird
|
|
NETBIRD_MGMT_DATASTORE_USER: netbird
|
|
NETBIRD_MGMT_DATASTORE_PASSWORD: ${POSTGRES_PASSWORD:-netbird123}
|
|
# Redis
|
|
NETBIRD_MGMT_DATASTORE_CACHE: "redis"
|
|
NETBIRD_MGMT_DATASTORE_REDIS_URL: "redis://redis:6379"
|
|
# Management API
|
|
NETBIRD_MGMT_API_PORT: "33073"
|
|
NETBIRD_MGMT_LOG_LEVEL: debug
|
|
NETBIRD_MGMT_SINGLE_ACCOUNT_MODE: "true"
|
|
NETBIRD_MGMT_DISABLE_SINGLE_ACCOUNT_MODE_REQUIRE_CUSTOM_DOMAIN: "true"
|
|
# OIDC disabled
|
|
NETBIRD_MGMT_AUTH_OIDC_CONFIGURATION_ENDPOINT: ""
|
|
ports:
|
|
- "33073:33073"
|
|
volumes:
|
|
- management_data:/var/lib/netbird
|
|
- ./management.json:/etc/netbird/management.json
|
|
networks:
|
|
- netbird
|
|
restart: "no"
|
|
|
|
signal:
|
|
image: netbirdio/signal:0.70.5
|
|
container_name: netbird-signal
|
|
environment:
|
|
NETBIRD_SIGNAL_LOG_LEVEL: info
|
|
NETBIRD_SIGNAL_PORT: 10000
|
|
ports:
|
|
- "10000:10000/tcp"
|
|
- "10000:10000/udp"
|
|
networks:
|
|
- netbird
|
|
depends_on:
|
|
- management
|
|
|
|
dashboard:
|
|
image: netbirdio/dashboard:latest
|
|
container_name: netbird-dashboard
|
|
environment:
|
|
REACT_APP_API_URL: ${DASHBOARD_API_URL:-http://localhost:33073}
|
|
ports:
|
|
- "80:80"
|
|
networks:
|
|
- netbird
|
|
depends_on:
|
|
- management
|
|
|
|
coturn:
|
|
image: coturn/coturn:latest
|
|
container_name: netbird-turn
|
|
ports:
|
|
- "3478:3478/tcp"
|
|
- "3478:3478/udp"
|
|
- "5349:5349/tcp"
|
|
- "5349:5349/udp"
|
|
volumes:
|
|
- ./coturn.conf:/etc/coturn/turnserver.conf:ro
|
|
- turn_data:/var/lib/coturn
|
|
networks:
|
|
- netbird
|
|
restart: unless-stopped
|
|
|
|
volumes:
|
|
postgres_data:
|
|
redis_data:
|
|
management_data:
|
|
turn_data:
|
|
|
|
networks:
|
|
netbird:
|
|
driver: bridge
|