Skip to content

fix: replace GitHub token checkout with SSH keys - #666

Merged
liuwei08 merged 1 commit into
masterfrom
fix/infrabox-ssh-key-recovery
Dec 4, 2026
Merged

liuwei08 merged 1 commit into
masterfrom
fix/infrabox-ssh-key-recovery

Conversation

@liuwei08

@liuwei08 liuwei08 commented Dec 4, 2026

Copy link
Copy Markdown
Contributor

GitHub checkout currently prefers the project owner's OAuth token, leaving builds dependent on stale user credentials. Use the existing project SSH key for clone, fetch, submodules and nested git jobs. Normalize configured GitHub HTTP(S) URLs to SSH and remove the token credential helper, checkout allowlist and HTTPS-to-SSH fallback. Keep the opt-in API token export; GITHUB_BASE_URL no longer embeds credentials.

Include a documented per-project deploy-key recovery script under scripts/infrabox-ssh-key-recovery. It registers a read-only GitHub key, verifies SSH clone before updating repository.private_key, preserves concurrent changes, and retains the new key when a database update has an uncertain outcome. No private keys or tokens are included.

Validation:

The live job validates the configured key and SSH connectivity. The runner code in this PR has not been deployed.

@liuwei08
liuwei08 merged commit 07450bc into master Dec 4, 2026
2 checks passed
@liuwei08
liuwei08 deleted the fix/infrabox-ssh-key-recovery branch December 4, 2026 05:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant