# legacy-api on the MIG instance (experiment design 3.2). Image tag is pinned to the apps repo commit. # alloy (WP-15, design 4.1): scrapes legacy-api /metrics (up{job="legacy-api"} feeds LegacyUnhealthy) into Mimir and # ships the container logs to Loki. Runs as root for the docker socket (log discovery). services: legacy-api: image: asia-northeast1-docker.pkg.dev/cms-d-414903/selfheal/legacy-api:7186ef0 container_name: legacy-api restart: always ports: - "8080:8080" environment: PORT: "8080" DB_DSN: "${DB_DSN}" healthcheck: test: ["CMD", "wget", "-qO-", "http://127.0.0.1:8080/healthz"] interval: 10s timeout: 3s retries: 3 alloy: image: grafana/alloy:v1.20.1 container_name: alloy restart: always user: "0" command: ["run", "--server.http.listen-addr=127.0.0.1:12345", "--storage.path=/var/lib/alloy/data", "/etc/alloy/config.alloy"] environment: INSTANCE: "${INSTANCE}" volumes: - ./config.alloy:/etc/alloy/config.alloy:ro - /var/run/docker.sock:/var/run/docker.sock:ro - alloy-data:/var/lib/alloy/data volumes: alloy-data: {}