feat: read tunnel endpoint from /etc/glueops/tunnel_endpoint - #550
Merged
Conversation
dev() targets the sish host from /etc/glueops/tunnel_endpoint when present (written by cloud-init on regional-tunnel deployments), falling back to the legacy central tunnels.glueopshosted.com. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ErBUiAYTosnpbF9hvUj3Dn
Legacy central sish appends the SSH username to the "cde" bind (cde-<name>.tunnels...); regional instances don't run that flag, so the VM binds its own hostname and URLs drop the redundant cde- prefix (<name>.<region>.tunnels.cde.glueopshosted.com). The bind derives from the endpoint value, matching the slackbot's URL rule. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ErBUiAYTosnpbF9hvUj3Dn
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.
What
Makes the sish tunnel endpoint configurable per VM instead of hardcoded.
dev()now reads/etc/glueops/tunnel_endpoint(written by cloud-init on newer platform deployments) and falls back to the legacytunnels.glueopshosted.comwhen the file is absent or empty:The bind name follows the same endpoint-value rule: on the legacy central endpoint the VM binds
cde(that sish runs--append-user-to-subdomain, producingcde-<hostname>.tunnels...), while on any regional endpoint it binds its bare$HOSTNAME, producing<hostname>.<region>.tunnels.cde.glueopshosted.com— no redundantcde-prefix. The slackbot'scdeAccessUrl()derives URLs from the identical rule, so tunnel and URL can never disagree.This is part of the regional tunnel endpoints rollout: each datacenter gets its own sish instance (
<region>.tunnels.cde.glueopshosted.com, run WITHOUT--append-user-to-subdomainand with--bind-random-subdomains=false) so codespaces connect to the closest tunnel instead of the single central one. Companion PRs: GlueOps/provisioner (tunnel_endpointregion config field) and GlueOps/slackbot-developer-workspaces (endpoint resolution, VM tagging, access URLs, cloud-init file write).Backward compatibility
/etc/glueops/tunnel_endpointfile behaves exactly as before (central tunnel).REGIONAL_TUNNEL_MIN_IMAGE_TAGgate controls only whether its value can be regional. Images below the gate get the legacy central value — which the old bakeddev()ignores (hardcoded central) and the newdev()resolves to identical behavior — so there is no deploy-order hazard in either direction.How to upgrade
v0.155.0).REGIONAL_TUNNEL_MIN_IMAGE_TAGin the slackbot's environment — the slackbot only assigns regional endpoints to VMs whose selected image is at/above it. Images older than this release bake adev()that ignores the file, so the gate keeps their tunnels and access URLs consistent (legacy central).🤖 Generated with Claude Code