From cf5349cdd2e710bcb3af3fdce3c6efb3058ea5b5 Mon Sep 17 00:00:00 2001 From: Till JS Date: Thu, 7 May 2026 15:42:54 +0200 Subject: [PATCH] feat(gpu-box): adopt photon container into compose with healthcheck MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit photon was the last 'health: none' container on the GPU-Box — pre-existing user setup created via raw docker-run before Phase 2. Adopted into infrastructure/docker-compose.gpu-box.yml with the exact same image / volumes / cmd / port mapping so the OSM index in /opt/photon-data survives untouched, plus a curl-based healthcheck against /api?q=Berlin&limit=1 (Photon has no /health endpoint — this is the canonical liveness probe). start_period 120s gives Java the warmup window without false-flagging. Recreate took ~10s including healthy state, no perceptible downtime on photon.mana.how. After this, all 20 GPU-Box containers report healthy. Mac Mini still has 2 long-standing 'unhealthy' (mana-verdaccio's wget probe is broken but npm.mana.how serves 200; mana-mail/Stalwart in bootstrap mode, never configured) — both pre-existing, neither user-impacting. Co-Authored-By: Claude Opus 4.7 (1M context) --- infrastructure/docker-compose.gpu-box.yml | 37 +++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/infrastructure/docker-compose.gpu-box.yml b/infrastructure/docker-compose.gpu-box.yml index 1c8185108..bbfc5a665 100644 --- a/infrastructure/docker-compose.gpu-box.yml +++ b/infrastructure/docker-compose.gpu-box.yml @@ -98,6 +98,43 @@ services: retries: 3 start_period: 30s + # ============================================ + # Photon Geocoder (pre-existing user container, adopted into compose + # 2026-05-07 to gain a healthcheck). Backs mana-geocoding's + # `privacy:'local'` provider via photon.mana.how (GPU-tunnel). + # OSM index lives in /opt/photon-data on the WSL2 host — survives + # container recreation. + # ============================================ + photon: + image: eclipse-temurin:21-jre + container_name: photon + restart: unless-stopped + working_dir: /photon + environment: + LC_ALL: en_US.UTF-8 + ports: + - '2322:2322' + volumes: + - /opt/photon-data/photon.jar:/photon/photon.jar:ro + - /opt/photon-data/photon_data:/photon/photon_data + command: + - java + - -jar + - photon.jar + - serve + - -listen-ip + - 0.0.0.0 + - -listen-port + - '2322' + healthcheck: + # Photon hat keinen /health-Endpoint — kanonische Probe ist eine + # winzige Geocoding-Query. Limit=1 hält den Response klein. + test: ['CMD-SHELL', 'curl -sf -o /dev/null "http://127.0.0.1:2322/api?q=Berlin&limit=1" || exit 1'] + interval: 60s + timeout: 10s + retries: 3 + start_period: 120s + # ============================================ # Phase 2c — Metrics-Stack # ============================================