-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.local.yml
More file actions
88 lines (83 loc) · 2.1 KB
/
docker-compose.local.yml
File metadata and controls
88 lines (83 loc) · 2.1 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
services:
backend:
build:
context: ./backend
dockerfile: Dockerfile
ports:
- "5001:5001"
restart: always
networks:
- local
- api_network
depends_on:
database:
condition: service_healthy
env_file:
- ./.env
environment:
- ASPNETCORE_URLS=http://+:5001
- DEFAULT_CONNECTION=Server=database,1433;Database=${DB_NAME};User Id=${DB_USER};Password=${DB_ADMIN_PASS};Trust Server Certificate=True
- ASPNETCORE_ENVIRONMENT=Development
deploy:
resources:
limits:
cpus: '2'
memory: '256M'
reservations:
memory: '128M'
frontend:
build:
context: ./frontend
dockerfile: Dockerfile
args:
- VITE_BASE_URI=${VITE_BASE_URI}
volumes:
- ${CERT_PATH:-./Dev}:/etc/letsencrypt/live/emaaha.ddns.net:ro
- ${ARCHIVE_PATH:-./Dev}:/etc/letsencrypt/archive/emaaha.ddns.net:ro
ports:
- "8080:8080" # Changed to avoid conflict with system services
- "8443:443"
deploy:
resources:
limits:
cpus: '2'
memory: '128M'
reservations:
memory: '64M'
restart: always
environment:
CERT_PATH: ${CERT_PATH:-./Dev}
ARCHIVE_PATH: ${ARCHIVE_PATH:-./Dev}
BACKEND_URL: ${BACKEND_URL:-http://backend:5001}
BACKEND_HOST: ${BACKEND_HOST:-backend:5001}
depends_on:
- backend
networks:
- api_network
database:
image: mcr.microsoft.com/mssql/server:2025-latest
environment:
- ACCEPT_EULA=Y
- MSSQL_SA_PASSWORD=${DB_ADMIN_PASS}
- DB_USER=${DB_USER}
volumes:
- db_local:/var/opt/mssql
networks:
- local
restart: always
ports:
- "1433:1433" # Expose for debugging
healthcheck:
test: ["CMD-SHELL", "/opt/mssql-tools18/bin/sqlcmd -S localhost -U ${DB_USER} -P ${DB_ADMIN_PASS} -C -Q 'SELECT 1' || exit 1"]
interval: 30s
timeout: 10s
retries: 5
start_period: 60s
networks:
local:
driver: bridge
internal: true
api_network:
driver: bridge
volumes:
db_local: