Skip to content

Allow explicit local backends in hosted dev builds - #13129

Merged
austinywang merged 1 commit into
mainfrom
issue-12758-hosted-launch-followup
Sep 20, 2026
Merged

austinywang merged 1 commit into
mainfrom
issue-12758-hosted-launch-followup

Conversation

@austinywang

@austinywang austinywang commented Sep 20, 2026 •

Copy link
Copy Markdown
Contributor

The AWS tagged build for the paste-latency fix failed before compilation because reload-build.yml cannot invoke the local HQ backend helper when backend_url is empty. Failed build.

Expose the existing remote/local backend policy as a workflow input. Remote remains the default and requires an explicit registered URL on hosted runners; local is an explicit choice for a separately running local dev server. Validate the selection before dependency installation using the existing backend resolver. Checkout credentials no longer persist in the build workspace.

This changes no paste or application runtime code. Follow-up to #13110, which Austin merged.

Validation: existing backend-resolver controls passed (missing helper, explicit local mode, conflicting/unknown modes, registered remote URL), workflow YAML parsed, Swift file budget and diff checks passed. A scheduled AWS M4 Pro tagged build is being rerun with explicit local mode; its artifact will be launched locally as requested. Local mode supports terminal/paste dogfood, while Cloud/sign-in requires a running local backend.


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.


Summary by cubic

Allows hosted dev builds to explicitly choose a local backend, so the AWS tagged build for the paste-latency fix can run against a separate local dev server instead of failing when backend_url is empty.

  • Adds a backend_mode workflow input (remote default, local for a separate local dev server).
  • Remote mode still requires a registered backend_url; local mode validates the selection with the existing backend resolver.
  • Checkout credentials no longer persist in the build workspace.
  • No paste or application runtime code changes.

Written for commit bc13a6f. Summary will update on new commits.

Review in cubic

@coderabbitai

coderabbitai Bot commented Sep 20, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

Next included review available in 2 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 10 included reviews currently available.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Repository: manaflow-ai/cmux/.coderabbit.yaml

Review profile: ASSERTIVE

Plan: Advanced

Run ID: 7acf38c6-ecf7-4438-ac94-a43c8eeae189

📥 Commits

Reviewing files that changed from the base of the PR and between 51173c6 and bc13a6f.

📒 Files selected for processing (1)
  • .github/workflows/reload-build.yml

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown
Contributor

All contributors have signed the CLA ✍️ ✅
Posted by the CLA Assistant Lite bot.

@austinywang
austinywang marked this pull request as ready for review September 20, 2026 04:54
@austinywang
austinywang merged commit d11d23b into main Sep 20, 2026
37 of 40 checks passed
@greptile-apps

greptile-apps Bot commented Sep 20, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 4/5

The workflow change appears safe to merge, with a non-blocking improvement needed to make early validation fail clearly when the selected source ref lacks the backend resolver.

Findings

  1. P2 Validation Silently Skips ▶

Summary

This PR exposes the existing local/remote backend policy as a workflow-dispatch input, validates macOS backend configuration before the build, and prevents checkout credentials from persisting.

  • Keeps remote mode as the default and requires a registered backend URL on hosted macOS builds.
  • Allows callers to select local mode for artifacts intended to use a separately running local development server.
  • Delegates detailed mode and URL validation to the existing backend resolver when it exists.
  • Disables persisted checkout credentials.

Reviews (1) · Last reviewed commit: "ci: support explicit local backends for ..."

Comment on lines +104 to +107
if [[ -f scripts/lib/dev-backend-origin.sh ]]; then
source scripts/lib/dev-backend-origin.sh
cmux_resolve_tagged_backend "$BUILD_TAG" "$GITHUB_WORKSPACE" "http://localhost:3777" >/dev/null
fi

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Validation Silently Skips

When inputs.ref selects a revision without scripts/lib/dev-backend-origin.sh, this step succeeds without validating the backend selection. The tagged build then continues through setup before reload.sh fails while sourcing the missing helper, so the intended early validation becomes a later failure with less useful guidance. Require the helper or report an actionable error in this step.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The conditional preserves builds of historical source refs. I checked the parent of the commit that introduced this helper: reload.sh at e42dc540df directly uses its local dev origin and never sources dev-backend-origin.sh. Its absence therefore does not cause the later missing-helper failure described here. The remote-URL presence check is unconditional; revisions that implement the backend resolver additionally run its URL/mode validation. Requiring that newer helper for every historical ref would reject otherwise buildable legacy sources. Keeping this compatibility path; no source change for this finding.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You’re right. The historical reload.sh at e42dc540df does not source dev-backend-origin.sh, so its absence cannot cause the later failure described in the comment. The unconditional remote-URL guard still enforces the new hosted-runner policy, while resolver validation is correctly limited to refs that contain the helper. I’m withdrawing this finding; no source change is needed.

rustybret pushed a commit to rustybret/bmux that referenced this pull request Sep 20, 2026
24c1cac Follow up Cloud startup latency and regression checks (manaflow-ai#13109)
e0e77eb Cloud splits preserve remote placement under concurrent creates (manaflow-ai#13098)
aa3e0e5 Fix persistent Cloud command deadline and cancellation races (manaflow-ai#12631)
d11d23b ci: support explicit local backends for hosted dev builds (manaflow-ai#13129)
51173c6 Reduce plain-text paste startup while preserving provider isolation (manaflow-ai#13110)
03974a9 Move web to @hexclave/next 1.0.121 so server getTeam fetches one team (manaflow-ai#13012)
57939a8 Team picker: switch/create teams and scope Cloud (manaflow-ai#13051)
fc7d002 fix(cloud): restore resource readings and reconcile resized capacity (manaflow-ai#13084)
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