Summary\n\n- Service definitions can now declare [[components.routes]] instead of manual port mappings\n- Agent allocates free host ports at deploy time (random 10000-60000, availability check)\n- Containers receive $PORT / $PORT_<NAME> env vars with assigned ports\n- Backward compatible: components with old-style ports= work unchanged\n\n## Changes\n\n- Proto: RouteSpec message, routes + env fields on ComponentSpec\n- Servicedef: RouteDef parsing and validation from TOML\n- Registry: component_routes table with host_port tracking\n- Runtime: Env field on ContainerSpec, -e flag in BuildRunArgs()\n- Agent: PortAllocator with mutex serialization, deploy wiring for route→port mapping + env injection\n\n## Test plan\n\n- [x] Servicedef: route parsing, validation (duplicate names, missing port, invalid mode), proto round-trip\n- [x] Registry: route CRUD, cascade delete, host_port updates\n- [x] Runtime: BuildRunArgs with env vars\n- [x] Port allocator: allocation, release, double-allocation returns different ports\n- [x] Agent deploy: deploy with routes (verify -p and -e args), deploy with old-style ports (backward compat)\n- [x] All tests pass (go test ./...)
## Summary\n\n- Service definitions can now declare `[[components.routes]]` instead of manual port mappings\n- Agent allocates free host ports at deploy time (random 10000-60000, availability check)\n- Containers receive `$PORT` / `$PORT_<NAME>` env vars with assigned ports\n- Backward compatible: components with old-style `ports=` work unchanged\n\n## Changes\n\n- **Proto**: `RouteSpec` message, `routes` + `env` fields on `ComponentSpec`\n- **Servicedef**: `RouteDef` parsing and validation from TOML\n- **Registry**: `component_routes` table with `host_port` tracking\n- **Runtime**: `Env` field on `ContainerSpec`, `-e` flag in `BuildRunArgs()`\n- **Agent**: `PortAllocator` with mutex serialization, deploy wiring for route→port mapping + env injection\n\n## Test plan\n\n- [x] Servicedef: route parsing, validation (duplicate names, missing port, invalid mode), proto round-trip\n- [x] Registry: route CRUD, cascade delete, host_port updates\n- [x] Runtime: BuildRunArgs with env vars\n- [x] Port allocator: allocation, release, double-allocation returns different ports\n- [x] Agent deploy: deploy with routes (verify -p and -e args), deploy with old-style ports (backward compat)\n- [x] All tests pass (`go test ./...`)
Service definitions can now declare routes per component instead of
manual port mappings:
[[components.routes]]
name = "rest"
port = 8443
mode = "l4"
The agent allocates free host ports at deploy time and injects
$PORT/$PORT_<NAME> env vars into containers. Backward compatible:
components with old-style ports= work unchanged.
Changes:
- Proto: RouteSpec message, routes + env fields on ComponentSpec
- Servicedef: RouteDef parsing and validation from TOML
- Registry: component_routes table with host_port tracking
- Runtime: Env field on ContainerSpec, -e flag in BuildRunArgs
- Agent: PortAllocator (random 10000-60000, availability check),
deploy wiring for route→port mapping and env injection
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
kyle
merged commit 5a802bceb6 into master2026-03-27 08:16:20 +00:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Summary\n\n- Service definitions can now declare
[[components.routes]]instead of manual port mappings\n- Agent allocates free host ports at deploy time (random 10000-60000, availability check)\n- Containers receive$PORT/$PORT_<NAME>env vars with assigned ports\n- Backward compatible: components with old-styleports=work unchanged\n\n## Changes\n\n- Proto:RouteSpecmessage,routes+envfields onComponentSpec\n- Servicedef:RouteDefparsing and validation from TOML\n- Registry:component_routestable withhost_porttracking\n- Runtime:Envfield onContainerSpec,-eflag inBuildRunArgs()\n- Agent:PortAllocatorwith mutex serialization, deploy wiring for route→port mapping + env injection\n\n## Test plan\n\n- [x] Servicedef: route parsing, validation (duplicate names, missing port, invalid mode), proto round-trip\n- [x] Registry: route CRUD, cascade delete, host_port updates\n- [x] Runtime: BuildRunArgs with env vars\n- [x] Port allocator: allocation, release, double-allocation returns different ports\n- [x] Agent deploy: deploy with routes (verify -p and -e args), deploy with old-style ports (backward compat)\n- [x] All tests pass (go test ./...)