Skip to content

devspaces-remote-ssh: Workspace discovery unusable for users with broad namespace access #23805

@achdmbp

Description

@achdmbp

Description

The Dev Spaces Local/Remote Support - SSH extension (v0.2.2026040208) fails to populate the Remote Explorer with SSH workspace entries when the user has access to a large number of OpenShift namespaces.

Environment

  • Extension version: 0.2.2026040208
  • OpenShift: 4.18.x (ROSA)
  • Dev Spaces: 3.27

Root Cause

getProjects() in src/utils/cluster.ts calls oc projects -q, returning every namespace the user can access (2,300+ in our case). getPods() then iterates each namespace sequentially, running oc get pods and oc set env pod/<name> --list per pod.

A Dev Spaces user only has one workspace namespace. The extension doesn't need to query all accessible namespaces.

Proposed Fix

PR submitted: redhat-developer/devspaces-remote-ssh#6

  • Replace oc projects -q with a label-selector query on app.kubernetes.io/component=workspaces-namespace
  • Filter by che.eclipse.org/username annotation for the current user
  • Add URL-based namespace resolution via oc get devworkspace --all-namespaces --field-selector=metadata.name=<name>
  • Fix unquoted IdentityFile path that breaks SSH on macOS (paths with spaces)

Tested on a ROSA cluster with 2,300+ namespaces. Discovery goes from hanging indefinitely to completing in under 2 seconds.

Metadata

Metadata

Assignees

Labels

kind/bugOutline of a bug - must adhere to the bug report template.team/CThis team is responsible for the the IDEs and Extensions

Type

No type

Projects

Status

✅ Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions