cyoda health — liveness probe
cyoda-go version 0.6.2
cli.health
Section titled “cli.health”cli.health — probe the admin listener’s /readyz endpoint.
SYNOPSIS
Section titled “SYNOPSIS”cyoda health
DESCRIPTION
Section titled “DESCRIPTION”cyoda health sends an HTTP GET to http://127.0.0.1:<port>/readyz and exits 0 if the server responds with HTTP 200. Any non-200 response or connection error causes exit 1.
The probe uses a hard-coded 2-second HTTP client timeout. This timeout is load-bearing: a deadlocked readiness handler looks identical to “server accepts the connection then hangs” from the client’s perspective. Without a timeout, Docker’s HEALTHCHECK would inherit the deadlock and never mark the container unhealthy.
The port is read from CYODA_ADMIN_PORT (default: 9091). The admin listener always binds to 127.0.0.1 from the probe’s perspective — cyoda health is designed to run inside the same container or on the same host as the server.
Primary consumers:
- Docker Compose —
HEALTHCHECKstanza in the service definition. - Helm chart —
readinessProbeinvokescyoda healthbefore the pod is marked ready.
OPTIONS
Section titled “OPTIONS”cyoda health accepts no flags.
ENVIRONMENT VARIABLES
Section titled “ENVIRONMENT VARIABLES”CYODA_ADMIN_PORT— Admin listener port to probe (default:9091).
EXIT CODES
Section titled “EXIT CODES”0— Server responded HTTP 200. Instance is ready.1— Connection failed, timed out, or server returned a non-200 status.
EXAMPLES
Section titled “EXAMPLES”# Basic probe (uses CYODA_ADMIN_PORT or default 9091)cyoda health
# Probe a server on a non-default admin portCYODA_ADMIN_PORT=19091 cyoda health
# Use in a shell scriptif cyoda health; then echo "server is ready"else echo "server not ready" >&2 exit 1fiSEE ALSO
Section titled “SEE ALSO”- telemetry
See also
Section titled “See also”cyoda help telemetry— cyoda-go integrates the OpenTelemetry Go SDK (go.opentelemetry.io/otel). WhenCYODA_OTEL_ENABLED=true, the binary initializes a trace provider and a meter provider at startup using OTLP HTTP exporters. WhenCYODA_OTEL_ENABLED=false(default), no OTel SDK is initialized and no spans or metrics are emitted; the global OTel provider remains a no-op.
Raw formats
Section titled “Raw formats”/help/cli/health.json— full descriptor (matchesGET /help/{topic}envelope)/help/cli/health.md— body only