Skip to content

feat(selfhost): recognize brokered mode in the setup wizard + docker - #1346

Merged
JSONbored merged 1 commit into
mainfrom
feat/orb-brokered-setup-gating
Jun 25, 2026
Merged

feat(selfhost): recognize brokered mode in the setup wizard + docker#1346
JSONbored merged 1 commit into
mainfrom
feat/orb-brokered-setup-gating

Conversation

@JSONbored

Copy link
Copy Markdown
Owner

Summary

A brokered self-host (using the central Orb App instead of creating its own GitHub App) has no GITHUB_APP_ID, so the first-run setup wizard would wrongly walk the operator through creating their own App. This short-circuits /setup to a brokered-mode page when ORB_ENROLLMENT_SECRET is present (the central Orb provides credentials on demand), and documents the brokered env in Docker.

  • renderBrokeredSetupPage() (tested) + the server.ts gate (the entry is codecov-ignored — exercised by the Docker build+boot smoke test) placed before the own-App wizard.
  • docker-compose.yml: a brokered-mode block pointing at ORB_ENROLLMENT_SECRET (from .env) + the optional ORB_BROKER_URL.

First of the brokered-self-host end-to-end series (broker client #1341 → this → secure self-enrollment → signed event relay).

Validation

  • npm run test:ci green; the new renderBrokeredSetupPage is covered (the server.ts gate is in the codecov-ignored entry).

Advances #1255.

A brokered self-host (ORB_ENROLLMENT_SECRET set, using the central Orb App instead of its own GitHub App) has
no GITHUB_APP_ID, so the first-run setup wizard would wrongly walk the operator through creating their own App.
Short-circuit /setup to a brokered-mode page when an enrollment secret is present (the central Orb provides
credentials on demand). Document the brokered env in docker-compose.yml.

- renderBrokeredSetupPage() (tested) + the server.ts gate (codecov-ignored entry, exercised by the docker boot
  smoke test) before the own-App wizard.
- docker-compose.yml: a brokered-mode block pointing at ORB_ENROLLMENT_SECRET (.env) + ORB_BROKER_URL.

Advances #1255.
@dosubot dosubot Bot added the size:S label Jun 25, 2026
@superagent-security

Copy link
Copy Markdown
Contributor

Superagent didn't find any vulnerabilities or security issues in this PR.

@codecov

codecov Bot commented Jun 25, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.25%. Comparing base (c72c98f) to head (e7fd8c8).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1346   +/-   ##
=======================================
  Coverage   95.25%   95.25%           
=======================================
  Files         188      188           
  Lines       20319    20320    +1     
  Branches     7320     7320           
=======================================
+ Hits        19355    19356    +1     
  Misses        378      378           
  Partials      586      586           
Files with missing lines Coverage Δ
src/selfhost/setup-wizard.ts 100.00% <100.00%> (ø)
🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@JSONbored JSONbored self-assigned this Jun 25, 2026
@JSONbored
JSONbored merged commit 000a1a3 into main Jun 25, 2026
19 checks passed
@JSONbored
JSONbored deleted the feat/orb-brokered-setup-gating branch June 25, 2026 09:41
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.

GitHub App identity unification + atomic webhook-secret swap (retire reviewwed[bot])

1 participant