Files
Backend-Api/docker-compose.yml

42 lines
943 B
YAML

version: '3.8'
services:
# ASP.NET Core Application with HTTPS Support
servicehost:
build:
context: .
dockerfile: ServiceHost/Dockerfile
container_name: gozareshgir-servicehost
# ✅ All environment variables are now in ServiceHost/.env
env_file:
- ServiceHost/.env
ports:
- "${HTTP_PORT:-5003}:80"
- "${HTTPS_PORT:-5004}:443"
volumes:
- ./ServiceHost/certs:/app/certs:ro
- app_storage:/app/Storage
- app_logs:/app/Logs
networks:
- gozareshgir-network
extra_hosts:
- "host.docker.internal:host-gateway"
healthcheck:
test: ["CMD", "curl", "-f", "-k", "https://localhost:443/health", "||", "exit", "1"]
interval: 30s
timeout: 10s
start_period: 40s
retries: 3
restart: unless-stopped
networks:
gozareshgir-network:
driver: bridge
volumes:
app_storage:
driver: local
app_logs:
driver: local