Skip to content

fix(site): refuse dev desk mount when Astro binds beyond loopback - #7

Draft
charlesberret wants to merge 2 commits into
mainfrom
cursor/dev-desk-loopback-bind-d20b
Draft

charlesberret wants to merge 2 commits into
mainfrom
cursor/dev-desk-loopback-bind-d20b

Conversation

@charlesberret

@charlesberret charlesberret commented Nov 12, 2026 •

Copy link
Copy Markdown
Owner

Summary

When surfaces.devDesk and edit.* are set, @shellside/site now refuses to inject /admin and /api/dev-content during astro dev if Astro's server.host would bind beyond loopback (server.host: true, 0.0.0.0, and similar). It logs one plain line at config setup. Opt in with edit.allowNonLoopback: true.

isLoopbackServerBind() treats omitted/false server.host and explicit loopback addresses as safe; true and wide binds are not.

Docs

docs/ARE_YOU_INSANE.md documents the default mount gate and warns against setting edit.allowNonLoopback: true casually.

Reference fixture alignment

apps/reference/site.config.ts edit.files now matches the toy fixture (profile/profile.yaml; dropped missing records.yaml / page-copy.yaml entries) so dev-desk smoke can run.

Checks

npm run test -w @shellside/site
# pass 12
# fail 0
npm run check:desk
check-desk: ok
Open in Web Open in Cursor 

Fixes LAB-2359

cursoragent and others added 2 commits November 12, 2026 02:05
By default the integration skips /admin and /api/dev-content when
server.host is not loopback-only, unless edit.allowNonLoopback is set.

Co-authored-by: Charles Berret <charlesberret@users.noreply.github.com>
Points profile at profile/profile.yaml and drops yaml paths the toy
fixture does not provide so check-desk smoke can pass.

Co-authored-by: Charles Berret <charlesberret@users.noreply.github.com>

This branch has not been deployed

No deployments
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.

2 participants