fix(homebrew): repair local driver bootstrap state#1527
Open
TaylorMutch wants to merge 2 commits into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fix the macOS Homebrew/local-driver bootstrap state that can leave Docker or Podman sandboxes unable to connect back to the gateway after an upgrade.
This addresses the installer/runtime repair gaps tracked in #1525 and covers the stale supervisor image symptom tracked in #1523.
Problem
During local macOS debugging we found three upgrade-state issues:
OPENSHELL_LOCAL_TLS_DIRbut did not copy the generated sandbox JWT keysopenshell-gateway generate-certs --output-dir ...skipped existing TLS bundles even when the server certificate was missing newer required SANs likehost.containers.internaldevorlatestThe stale TLS case broke the explicit Podman driver because its default gateway endpoint uses
https://host.containers.internal:17670, while older generated certs did not contain that SAN.Changes
jwt/signing.pem,jwt/public.pem, andjwt/kidinto the Homebrew service-local TLS directory before starting the gateway.DEFAULT_SERVER_SANSfromopenshell-bootstrapso local cert repair can compare existing certs against the same SAN set used for generation.certgento parse the existing server certificate SANs and refresh TLS material when required SANs are missing.dev/latest) before extracting the supervisor binary, with fallback to the local image if the refresh fails.newerpolicy while keeping pinned and digest references onmissing.Compatibility
Testing
git diff --checkpython3 -c 'import ast, pathlib; ast.parse(pathlib.Path("tasks/scripts/release.py").read_text())'cargo test -p openshell-bootstrap pkicargo test -p openshell-driver-docker supervisorcargo test -p openshell-server certgencargo test -p openshell-driver-podman supervisor_pull_policyFixes #1525
Related #1523