refactor(config): enforce gateway schema version 2 - #2814
Conversation
Signed-off-by: Jesse Jaggars <jjaggars@redhat.com>
Signed-off-by: Jesse Jaggars <jjaggars@redhat.com>
be4ecf7 to
4042128
Compare
Signed-off-by: Jesse Jaggars <jjaggars@redhat.com>
Review concern dispositions and completed follow-upThe hard schema-v2 cut remains intentional: OpenShell does not silently accept v1 configuration syntax. Compatibility is preserved at explicit operational boundaries where an upgrade must not break runtime behavior, persisted state, or stable Helm values.
Verification completed with targeted driver/server tests, Helm tests, |
Signed-off-by: Jesse Jaggars <jjaggars@redhat.com>
Signed-off-by: Jesse Jaggars <jjaggars@redhat.com>
Signed-off-by: Jesse Jaggars <jjaggars@redhat.com>
Signed-off-by: Jesse Jaggars <jjaggars@redhat.com>
Schema-v2 follow-up completedI implemented the remaining review findings while preserving the strict schema-v2 boundary.
Verification
The branch is now synchronized and pushed at |
Summary
Cut the gateway configuration surface over to strict schema version 2 and complete the compute-driver configuration normalization tracked by #2792. The schema gives each setting one canonical name and owner, replaces sentinel values with typed optional values, centralizes shared driver models, and preserves runtime and persisted-state guarantees at explicit compatibility boundaries.
Related Issue
Closes #2792
Changes
[openshell] version = 2; reject omitted, version 1, and unsupported future schemas with migration-focused diagnostics.compute_driver,--compute-driver, andOPENSHELL_COMPUTE_DRIVER; reject legacycompute_drivers,--drivers, andOPENSHELL_DRIVERSinputs, including an explicitly empty legacy environment variable.[openshell.drivers.<name>]; reject non-table driver entries and stale Docker, Podman, and VM aliases.Always,IfNotPresent, andNever) to schema-v2 values while rejecting unsupported policies during rendering.ProvisioningwithSupervisorNotConnecteduntil the supervisor control session connects.Breaking migration notes
[openshell] version = 2and use the singular driver selector.[openshell.gateway]; move them into the selected driver table. Keep onlyguest_tls_ca,guest_tls_cert, andguest_tls_keyat gateway scope.sandbox_namespacetosandbox_label, Podmansandbox_ssh_socket_pathtossh_socket_path, and VMopenshell_endpointtogrpc_endpoint.always,if_not_present,never, or Podman-onlynewer. Existing Helm values may retain Kubernetes spellings because the chart normalizes them.The complete migration procedure and schema-v2 examples are in
docs/reference/gateway-config.mdx.Testing
mise run pre-commitmise run testmise run cimise run helm:testkeep-idcase cannot run because host UID16446is absent from the passwd database/dev/kvmis absent)The local Git configuration signs tags globally, so repository-wide test commands used a process-local
tag.gpgSign=falseoverride for temporary test repositories. This does not affect product behavior or committed Git configuration.Checklist