A bare GET / previously returned an empty 404, which reads as an outage even while the service is healthy. The root now redirects to /diagnostics when the dashboard is enabled and otherwise returns a small JSON status pointing at /health/live. The route is excluded from the OpenAPI description, so the frozen v1 surface is unchanged. The chiseled runtime image ships no shell or curl, so the container healthcheck re-enters the server assembly with --health-probe, which queries the local liveness endpoint and reports through the exit code. Dockerfile and compose both wire the probe (30s interval, 3 retries).
48 lines
1.7 KiB
YAML
48 lines
1.7 KiB
YAML
name: rendezvous-local
|
|
|
|
services:
|
|
rendezvous:
|
|
image: "${RENDEZVOUS_IMAGE:-finalfactory/rendezvous:local}"
|
|
build:
|
|
context: ../..
|
|
dockerfile: Dockerfile
|
|
init: true
|
|
user: "${RENDEZVOUS_UID:?set RENDEZVOUS_UID to a non-root host UID}:${RENDEZVOUS_GID:?set RENDEZVOUS_GID to its GID}"
|
|
read_only: true
|
|
tmpfs:
|
|
- /tmp:rw,noexec,nosuid,nodev,size=16m,uid=${RENDEZVOUS_UID},gid=${RENDEZVOUS_GID},mode=0700
|
|
cap_drop:
|
|
- ALL
|
|
security_opt:
|
|
- no-new-privileges:true
|
|
pids_limit: 128
|
|
mem_limit: 512m
|
|
cpus: 1.0
|
|
ulimits:
|
|
nofile:
|
|
soft: 4096
|
|
hard: 4096
|
|
stop_grace_period: 40s
|
|
restart: unless-stopped
|
|
healthcheck:
|
|
test: ["CMD", "dotnet", "FinalFactory.Rendezvous.Server.dll", "--health-probe"]
|
|
interval: 30s
|
|
timeout: 5s
|
|
retries: 3
|
|
start_period: 15s
|
|
environment:
|
|
ASPNETCORE_ENVIRONMENT: Production
|
|
ASPNETCORE_HTTP_PORTS: "8080"
|
|
Rendezvous__Diagnostics__Enabled: "${RENDEZVOUS_DIAGNOSTICS_ENABLED:-false}"
|
|
Rendezvous__Metrics__Enabled: "${RENDEZVOUS_METRICS_ENABLED:-false}"
|
|
volumes:
|
|
- ${RENDEZVOUS_CONFIG_SOURCE:-./appsettings.Production.json}:/app/appsettings.Production.json:ro
|
|
- ${RENDEZVOUS_SECRET_SOURCE:-./secrets/signing-key}:/run/secrets/rendezvous-signing-key:ro
|
|
ports:
|
|
- "127.0.0.1:${RENDEZVOUS_HTTP_HOST_PORT:-8080}:8080/tcp"
|
|
# 9050 is also a common game-client default UDP port. Evaluating this
|
|
# service on the same machine as a running game client can silently
|
|
# collide; remap with RENDEZVOUS_UDP_HOST_PORT and keep the advertised
|
|
# Rendezvous:Deployment:PublicUdpPort in appsettings matched to it.
|
|
- "${RENDEZVOUS_UDP_HOST_PORT:-9050}:9050/udp"
|