Lubien

I'm a passionate Web Developer and sometimes Platform Developer with Experience primarily in Elixir, JavaScript and some Golang.

Ping me
  • Aug 25, 2026

SSH directly into your sprite

Quick recipe to make ssh my-sprite.my-org just work, using sprite proxy under the hood.

Assumes:

  • sprite CLI installed and authenticated (get it at sprites.dev)
  • An SSH keypair at ~/.ssh/sprite_id / ~/.ssh/sprite_id.pub
  • git configured locally with user.name and user.email (optional — only if you want them copied over)

Step 1: Create the sprite and install sshd

export SPRITE_NAME=my-sprite
export SPRITE_ORG=my-org

sprite create $SPRITE_NAME -o $SPRITE_ORG --skip-console

sprite exec -s $SPRITE_NAME -o $SPRITE_ORG -- bash -ceu "sudo apt update && sudo apt install -y openssh-server && sprite-env services create sshd --cmd /usr/sbin/sshd && echo 'export PATH=\"/.sprite/bin:\$PATH\"' >> ~/.bashrc && echo 'export PATH=\"/.sprite/bin:\$PATH\"' >> ~/.zshrc && echo 'export PATH=\"/.sprite/bin:\$PATH\"' >> ~/.profile"

sprite exec -s $SPRITE_NAME -o $SPRITE_ORG -- bash -ceu "mkdir -p .ssh"

GIT_USERNAME=$(git config user.name) GIT_EMAIL=$(git config user.email) && sprite exec -s $SPRITE_NAME -o $SPRITE_ORG -- bash -ceu "git config --global user.name $GIT_USERNAME; git config --global user.email $GIT_EMAIL"

cat ~/.ssh/sprite_id.pub | sprite exec -s $SPRITE_NAME -o $SPRITE_ORG -- tee -a .ssh/authorized_keys

Step 2: Add this to ~/.ssh/config

Replace my-org with your sprite organization name.

Host *.my-org
    User sprite
    IdentityFile ~/.ssh/sprite_id
    ProxyCommand bash -ceu 'FULL="%h" && sprite proxy -s ${FULL%%.*} -o my-org -W 22'
    ServerAliveInterval 30
    ServerAliveCountMax 3

Step 3: Connect

ssh my-sprite.my-org

That’s it. The .my-org suffix is just a routing hint for SSH — the ProxyCommand strips it and talks to sprite proxy, so any tool that speaks SSH (rsync, scp, VS Code Remote-SSH, etc.) works out of the box.