Install the client tools and sign in
Beams is a Teleport project and uses official Teleport client tools.
The client tools include tsh to sign in and run commands, and tctl to administer your cluster if you have permission.
Cluster: example.beams.run. Edit this example to use your cluster name.
Install version 18.11.10 of the client:
Download and open the macOS installer, then follow its instructions.
curl -O https://cdn.teleport.dev/teleport-tools-18.11.10.pkg
open teleport-tools-18.11.10.pkgFor Linux x86-64, download and install the client tools:
curl -O https://cdn.teleport.dev/teleport-v18.11.10-linux-amd64-bin.tar.gz
tar -xzf teleport-v18.11.10-linux-amd64-bin.tar.gz
sudo ./teleport/installFor Windows x86-64, run these commands in PowerShell. Add the extraction directory ($env:LOCALAPPDATA\Teleport) to your user PATH to use tsh in future terminals; the last command adds it to this terminal's PATH.
Invoke-WebRequest -Uri https://cdn.teleport.dev/teleport-v18.11.10-windows-amd64-bin.zip -OutFile teleport.zip
Expand-Archive -Path teleport.zip -DestinationPath "$env:LOCALAPPDATA\Teleport" -Force
$env:Path += ";$env:LOCALAPPDATA\Teleport"Follow the official client tools install guide for other versions and architectures.
Check that you’re running v18.11.10 of the client with tsh version.
tsh versionI sign in without a password (e.g. a passkey).
tsh login --proxy='example.beams.run' --auth=passwordlessI have a password & MFA set up for my account:
Replace you@example.com with your Teleport username.
tsh login --proxy='example.beams.run' --user=you@example.comI sign in with SSO (e.g. Okta, GitHub, SAML).
tsh login --proxy='example.beams.run'Start a beam - a micro-VM. This beam starts with a pre-packaged and auto-updating Pi connected to an LLM inference endpoint:
tsh beams addStart Pi in a managed session:
# start pi in a background, and attach to it:
beamctl start --pty -- pi
# to detach, press Ctrl-Z, to reattach back use beamctl list and beamctl attachWhy not just run pi directly?
You can do this too, but the command above started pi in background, allocated terminal and attached to it.
You can detach by typing Ctrl-Z, or close the tab, and reattach later:
tsh beams ssh <beam-name>Find the Pi service ID, then reattach to it:
beamctl list
beamctl attach <service-id>You may need to recover your terminal if you got disconnected, some coding harnesses break it:
stty sane
resetChoosing a model
Teleport Beams offers several built-in models, once in pi harness, try this:
/modelsConnect Pi to GitHub
Your agent uses GitHub through Teleport, so you never put a personal access token or SSH key in the beam. Teleport authorizes each git and tsh gh call and logs it in the audit log.
1. Connect your GitHub organization
Skip this step if tsh git ls already lists your organization. Otherwise, a Teleport admin with the editor role runs the following on a workstation with a browser, while signed in to GitHub as an owner of the organization. Replace my-org with your organization:
tctl integrations github add --org=my-org --dry-run
tctl integrations github add --org=my-orgThe dry run prints the plan without making changes. The second command creates the Teleport integration, opens your browser to create a GitHub App, and saves the app's credentials in Teleport. Install the app on Only select repositories, and choose the repositories your agent may work on. The agent can't reach any other repository. If the app name, which defaults to your cluster name, is taken on GitHub, add --app-name=my-org-teleport.
The command doesn't grant anyone access. Save this role as github-my-org.yaml:
kind: role
version: v8
metadata:
name: github-my-org
spec:
allow:
github_permissions:
- orgs: [my-org]Create the role, and assign it to the people who run agents in beams through your usual role mapping:
tctl create -f github-my-org.yaml2. Authorize GitHub and start the beam
Sign in to GitHub through Teleport once from your workstation. This links your GitHub account to your Teleport user:
tsh git ls
tsh git login --github-org=my-orgtsh beams add shares this connected account with new beams by default. The agent then acts as your GitHub user, limited by both your GitHub permissions and the repositories you installed the app on. If you pass --roles, include github-my-org, or the beam can't see the organization:
tsh beams add --roles=beam-user,github-my-orgDon't pass --no-share-connected-accounts: that flag starts the beam without your GitHub authorization.
3. Check access from the beam
Inside the beam, confirm that the organization is listed and which GitHub account Teleport uses:
tsh git ls
tsh gh --github-org=my-org -- api /user --jq .loginIf tsh gh prints an authorization URL, open it on your workstation, finish signing in, and retry.
Ask Pi to work on a repository
You don’t need to configure Pi. Each beam has ~/AGENTS.md, which tells agents to clone with tsh git clone and to use tsh gh -- in place of gh. Pi loads it when you start Pi in your home directory or below. Start Pi and give it a task:
Clone https://github.com/my-org/my-repo, fix the typo in README.md on a new
branch, push it, and open a pull request.The agent works with ordinary Git commands and tsh gh. Beams don't set a Git author, so ask the agent to set git config user.name and user.email in the checkout first, or include them in your prompt. A typical run looks like this:
tsh git clone https://github.com/my-org/my-repo.git
cd my-repo
git switch -c fix-readme-typo
git commit -am 'Fix README typo'
git push -u origin HEAD
tsh gh --github-org=my-org -- pr create -R my-org/my-repo --filltsh git clone sets the remote to a teleport:// URL, so plain git fetch and git push keep going through Teleport. For a checkout that already exists in the beam, tell the agent to run tsh git config update in it first. The agent can't bypass branch protection or repository rules, so you still review and merge its pull requests.
See GitHub for SSH-only organizations, troubleshooting and audit events.