-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
executable file
·92 lines (86 loc) · 3.32 KB
/
docker-compose.yml
File metadata and controls
executable file
·92 lines (86 loc) · 3.32 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
# =============================================================================
# docker-compose.yml
#
# Local development environment for Ando.Server.
# Includes SQL Server for database and volume mounts for Docker-in-Docker.
#
# Usage:
# docker compose up -d # Start all services
# docker compose logs -f # Follow logs
# docker compose down # Stop all services
# docker compose down -v # Stop and remove volumes
# =============================================================================
services:
# ---------------------------------------------------------------------------
# Ando Server
# ---------------------------------------------------------------------------
ando-server:
build:
context: .
dockerfile: src/Ando.Server/Dockerfile
ports:
- "17100:8080"
environment:
- ASPNETCORE_ENVIRONMENT=Development
- ConnectionStrings__DefaultConnection=Server=sqlserver;Database=AndoServer;User Id=sa;Password=YourPassword123!;TrustServerCertificate=true
# Override these with your actual GitHub App credentials
- GitHub__AppId=${GITHUB_APP_ID:-}
- GitHub__ClientId=${GITHUB_CLIENT_ID:-}
- GitHub__ClientSecret=${GITHUB_CLIENT_SECRET:-}
- GitHub__WebhookSecret=${GITHUB_WEBHOOK_SECRET:-}
# Override with your Resend API key and optional base URL for Resend-compatible providers
- Email__Resend__ApiKey=${RESEND_API_KEY:-}
- Email__Resend__BaseUrl=${RESEND_BASE_URL:-}
# Encryption key (generate with: openssl rand -base64 32)
- Encryption__Key=${ENCRYPTION_KEY:-dGhpc2lzYWRldmVsb3BtZW50a2V5b25seTMyYnl0ZXM=}
volumes:
# Docker socket for Docker-in-Docker builds
- /var/run/docker.sock:/var/run/docker.sock
# Persistent storage for build artifacts
- artifacts:/data/artifacts
# Persistent storage for cloned repositories
- repos:/data/repos
# Persistent storage for ASP.NET Core Data Protection keys (prevents logouts on container rebuild/recreate)
- keys:/data/keys
# Mount GitHub App private key if using file-based key
- ./github-app.pem:/app/github-app.pem:ro
depends_on:
sqlserver:
condition: service_healthy
restart: unless-stopped
# ---------------------------------------------------------------------------
# SQL Server Database
# ---------------------------------------------------------------------------
sqlserver:
image: mcr.microsoft.com/mssql/server:2022-latest
environment:
- ACCEPT_EULA=Y
- MSSQL_SA_PASSWORD=YourPassword123!
- MSSQL_PID=Developer
ports:
- "17133:1433"
volumes:
- sqldata:/var/opt/mssql
healthcheck:
test: /opt/mssql-tools18/bin/sqlcmd -S localhost -U sa -P "YourPassword123!" -C -Q "SELECT 1" || exit 1
interval: 10s
timeout: 5s
retries: 10
start_period: 30s
restart: unless-stopped
# -----------------------------------------------------------------------------
# Named Volumes
# -----------------------------------------------------------------------------
volumes:
# SQL Server data
sqldata:
driver: local
# Build artifacts storage
artifacts:
driver: local
# Cloned repository storage
repos:
driver: local
# Data Protection keys (auth cookies become invalid if these are lost)
keys:
driver: local