Skip to content

bug(snap): sandbox ssh-config ProxyCommand uses the revision path and fails with "Unknown gateway" #5551

Open

Description

@RafiB982

User Story

I use OpenShell (snap) on Ubuntu to run coding agents in Docker-driver sandboxes.
I directly encountered this when connecting to a sandbox with plain ssh/scp through the config printed by openshell sandbox ssh-config, which is what editors such as VS Code Remote-SSH use.
This affects every snap user who connects with an SSH client instead of openshell sandbox connect.

Problem Statement

On the snap, openshell sandbox ssh-config <name> prints a ProxyCommand that calls the binary inside a specific snap revision:

ProxyCommand /snap/openshell/2564/bin/openshell ssh-proxy --gateway-name openshell --name hs-test-9 --workspace default

Run this way, the CLI bypasses the snap launcher and doesn't see the gateway registration that openshell gateway add stored under the snap's home (~/snap/openshell/common/...). Every SSH connection fails:

Error:   × Unknown gateway 'openshell'.
  │ Register it first: openshell gateway add <endpoint> --name openshell

The path also hard-codes the revision (2535 on 0.1.8, 2564 on 0.1.9-pre.3), so a saved config would break on the next snap refresh even if it worked.

Impact / Why This Matters

SSH-based workflows (ssh, scp, editor remote-SSH) don't work on the snap out of the box. Users must hand-edit the generated config to call /snap/bin/openshell ssh-proxy ... instead. With that edit, ssh, piped scripts and scp all work.

Acceptance Criteria

  • On the snap, ssh -F <(openshell sandbox ssh-config NAME) openshell-NAME.default true succeeds with a gateway registered via openshell gateway add ... --local.
  • The generated ProxyCommand keeps working after a snap refresh to a new revision.

Reproduction Steps

  1. Install the snap, start the user gateway, and register it: openshell gateway add https://127.0.0.1:17670 --local --name openshell
  2. openshell sandbox create --name demo --detach --no-tty --no-auto-providers
  3. openshell sandbox ssh-config demo > /tmp/demo_ssh_config (any path)
  4. ssh -F /tmp/demo_ssh_config openshell-demo.default true, which fails with "Unknown gateway 'openshell'"
  5. Replace /snap/openshell/<rev>/bin/openshell with /snap/bin/openshell in the ProxyCommand; step 4 now succeeds.

Suggested UX (if applicable)

ProxyCommand /snap/bin/openshell ssh-proxy --gateway-name openshell --name demo --workspace default

Environment

  • OpenShell: 0.1.9-pre.3 (snap rev 2564, latest/beta); also reproduced on 0.1.8 (rev 2535, latest/stable)
  • OS: Ubuntu 26.04.1 LTS, kernel 7.0.0-43, snapd 2.78
  • Deployment: snap per-user gateway (snap.openshell.user-gateway), Docker compute driver, Docker 29.9.3 (docker-ce from apt)

Logs

$ ssh -F demo_ssh_config openshell-demo.default true
Error:   × Unknown gateway 'openshell'.
  │ Register it first: openshell gateway add <endpoint> --name openshell
  │ Or list available gateways: openshell gateway select

Activity

  1. added
    state:triage-needed
    on Nov 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    state:triage-needed

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions