codex - 💡(How to fix) Fix Support multiple SSH remote contexts in a single Codex thread

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

Error Message

Users have to open separate Codex threads for each SSH host, run diagnostics separately, manually copy summaries between chats, and coordinate decisions outside Codex. This is inefficient, error prone, and loses context.

Fix Action

Fix / Workaround

Current workaround

RAW_BUFFERClick to expand / collapse

Problem

Codex App appears to bind each thread to one selected local or SSH remote project at a time. This works well for single-host tasks, but it becomes limiting for infrastructure work that depends on comparing or coordinating multiple servers.

Use cases

  • Compare deployment state between two servers.
  • Migrate a service from one host to another.
  • Diagnose failures where one server depends on another.
  • Compare staging and production environments.
  • Audit Docker stacks, environment variables, logs, workers, app servers, database servers, and gateway servers across different machines.

Current workaround

Users have to open separate Codex threads for each SSH host, run diagnostics separately, manually copy summaries between chats, and coordinate decisions outside Codex. This is inefficient, error prone, and loses context.

Feature request

Allow a single Codex thread to attach to more than one SSH remote connection at the same time.

Suggested design:

  • Let users select multiple SSH connections for one thread.
  • Show each remote as a named context, for example:
    • server-a:/app/service
    • server-b:/app/worker
  • Require every command, file read, and file edit to be explicitly scoped to one host.
  • Make the active host visually obvious before running any command.
  • Support read-only mode for secondary hosts when the user only needs comparison or diagnostics.
  • Keep approvals separated per host.

Security and UX safeguards

  • Every shell command should show the target host before execution.
  • Every file diff should include the target host and path.
  • Destructive operations should require approval with the host name clearly visible.
  • Codex should never infer that permission on one host implies permission on another.
  • The UI should make cross-host operations explicit.

Expected benefit

This would make Codex more useful for infrastructure work, migrations, distributed systems, multi-server deployments, and staging/production audits. It would reduce manual copy-paste between separate threads while preserving clear host-level safety boundaries.

Suggested labels

enhancement, ssh, remote-connections, feature-request

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

codex - 💡(How to fix) Fix Support multiple SSH remote contexts in a single Codex thread