# Cloud and Server Commands

> How to run Claude Code on more than your laptop. Cloud sessions and /teleport, your own runners, a gateway for your staff, Remote Control and tmux panes.

**Course:** [Claude Code Commands](https://learn.benibix.com/learn/ai-claude-code-commands)  
**Time:** 12 min

**After this lesson you can:**

- Pull a cloud session into your terminal
- Start a cloud session on your own machines
- Pick the server command that fits

## How to run Claude Code beyond one terminal

Claude Code can run as a server with no chat in the terminal, in three ways. claude remote-control lets you drive it from claude.ai or the Claude phone app. The work still runs on your computer. claude gateway puts a company's sign-in and rules in front of it. claude self-hosted-runner runs cloud sessions on your own machines.

Cloud sessions run on Anthropic's machines by default. /web-setup links your GitHub account to them once. It uses the gh sign-in already on your computer. /remote-env picks the cloud setup that new sessions from the shell start with. /teleport, or /tp, pulls a cloud session into your terminal, with its branch and its chat.

claude remote-control, or claude rc, starts the server. --name sets the name you see in the app. Inside a chat that is already open, /remote-control lets you reach just that one chat. Either way, the work runs on your own computer. The phone is where you read and reply.

claude self-hosted-runner signs up a machine or a box of code to a pool of your own machines. setup walks you through it. doctor checks a runner that is already going. orchestrator starts new runners when they are needed. Then claude --environment, with an ID that starts ccpool_, sends a new cloud session there.

--environment starts from your current commit. Add --ref with a branch name to start from that branch instead. Both need Claude Code 2.1.224 or later. The point is that the code never leaves your own machines, which some companies require.

claude gateway is a tool for admins, not for one laptop. It puts your company's own sign-in and rules in front of Claude Code. The model runs on a cloud such as Amazon Bedrock. It needs --config with a gateway.yaml file. /setup-bedrock is for one person instead. It walks you through Bedrock sign-in, region and model pins.

/setup-bedrock stays out of the menu until CLAUDE_CODE_USE_BEDROCK is set to 1. Until then, type the whole name. Two flags set up panes in your terminal. --tmux opens a tmux session for a worktree, and only works with --worktree. --teammate-mode sets how team members show. It is in-process by default. Set it to tmux for a pane each.

## The three server commands

| Command | Who it is for | Where the work runs |
| --- | --- | --- |
| claude remote-control | You, away from your desk | Your own computer |
| claude gateway | A company's admins | A cloud such as Amazon Bedrock |
| claude self-hosted-runner | A team that keeps code in house | Your own machines |

```bash
claude remote-control --name "My Project"
claude self-hosted-runner setup
claude -p "Run the test suite" --environment ccpool_abc123 --ref main
claude gateway --config gateway.yaml
claude -w feature-auth --tmux
```
Drive this computer from the app and set up a runner. Send a cloud session to your machines, start a gateway, and open tmux panes.

![Three rows. claude remote-control runs on your computer and is driven from your phone. claude gateway adds company sign-in and rules for your staff. claude self-hosted-runner runs cloud sessions on your own machines. A note says each one runs as a server, with no chat in the terminal.](https://learn.benibix.com/diagrams/cli-servers.svg)

### Example: Emma checks a long job from her phone

Emma starts claude remote-control on her desktop at 6 pm. She names it nightly-migration with --name. On the train she opens the Claude app and finds the session by that name.

She answers the one question it asked. The migration of 40 files runs on her desktop the whole time.

**Words in this lesson:** [claude remote-control Command](https://learn.benibix.com/term/ai/claude-remote-control-command), [/web-setup Command](https://learn.benibix.com/term/ai/web-setup-command), [/remote-env Command](https://learn.benibix.com/term/ai/remote-env-command), [/teleport Command](https://learn.benibix.com/term/ai/teleport-command), [claude self-hosted-runner Command](https://learn.benibix.com/term/ai/claude-self-hosted-runner-command), [--environment Flag](https://learn.benibix.com/term/ai/environment-flag), [claude gateway Command](https://learn.benibix.com/term/ai/claude-gateway-command), [/setup-bedrock Command](https://learn.benibix.com/term/ai/setup-bedrock-command), [--tmux Flag](https://learn.benibix.com/term/ai/tmux-flag), [--teammate-mode Flag](https://learn.benibix.com/term/ai/teammate-mode-flag)

> **Where the work runs.** With remote-control, the work stays on your computer. With self-hosted-runner, cloud sessions move to your own machines. A gateway changes who may sign in, not where the work runs.

**Question:** Which command lets you drive a session on your own computer from your phone?

**Answer:** claude remote-control. claude remote-control keeps the work on your computer. The Claude app or claude.ai drives it. /teleport goes the other way. It pulls a cloud session down to you.

---

Source: https://learn.benibix.com/learn/ai-claude-code-commands/cloud-and-server-commands
Author: Behnia Zarei (a developer in Vienna, Austria, who builds and teaches data, AI and business intelligence at BENIBIX)
Publisher: BENIBIX Learn (https://learn.benibix.com/)
Last updated: 2026-11-19
Licence: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Quote freely with attribution.
