Expand description
Service launch surfaces with local-only endpoint exposure.
Provides service configuration and health endpoint definitions that
enforce binding to 127.0.0.1 only (never 0.0.0.0).
§Security Model
- All services bind to
127.0.0.1(localhost) only - No external interface exposure
- Health endpoints at
/healthrespond with HTTP 200 within 30 seconds
§Health Endpoints
Each service registers http://127.0.0.1:<port>/health which returns:
- HTTP 200 with JSON body
{"status": "ok"}when healthy - HTTP 503 with JSON body
{"status": "unhealthy"}when not healthy
This module does not start an actual HTTP server — it provides the configuration, address binding logic, and health check structures used by the runtime to manage services.
Structs§
- Health
Check Result - Result of a health check against a service.
- Service
Config - Configuration for a managed service.
- Service
Registry - Registry of managed services with their configurations.
Enums§
- Service
Error - Errors related to service management.
Constants§
- HEALTH_
PATH - Default health check path.
- HEALTH_
TIMEOUT - Default health check timeout (30 seconds).
- LOCALHOST
- Localhost IPv4 address — the only address services may bind to.
Functions§
- is_
localhost_ addr - Validate that a socket address is localhost only.
- validate_
bind_ address - Validate that a bind address string represents a localhost-only address.