The _check_control_plane_health() method probes localhost:18180, which is the control-plane's mapped port. Inside a bridged container, localhost resolves to the container's own loopback — the probe always fails. host network mode shares the VPS host's network namespace so that localhost:18180 correctly reaches the control-plane. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
11 lines
419 B
YAML
11 lines
419 B
YAML
services:
|
|
node-agent:
|
|
environment:
|
|
- NODE_NAME=vps
|
|
- CHECK_INTERVAL=60
|
|
# host network mode: node-agent on VPS shares the host's network namespace
|
|
# so that localhost:18180 resolves to the control-plane's exposed port.
|
|
# Without this, localhost inside the container is the container's own loopback
|
|
# and the _check_control_plane_health() probe would always fail.
|
|
network_mode: host
|