rune exec
rune exec <service-or-instance> [--] <command> [args...]Examples
Section titled “Examples”# Interactive shellrune exec api bash
# One-offrune exec api ls -la /app
# Specific instancerune exec api-instance-7c2e ps aux
# Workdir + env + commandrune exec api --workdir=/app --env=DEBUG=true python debug.py
# Non-interactiverune exec api --no-tty python script.py
# Bound timeoutrune exec api --timeout=30s python long.py| Flag | Default | Notes |
|---|---|---|
-n, --namespace | context | Target namespace. |
--workdir <dir> | runner | Working directory inside the instance. |
--env k=v | — | Extra env var (repeatable). |
--no-tty | false | Disable TTY allocation. |
--timeout <dur> | — | Bound the session. |
Behavior
Section titled “Behavior”- A service-name argument picks any healthy instance.
- An instance ID targets that exact instance.
- Stdin/stdout are forwarded full-duplex when a TTY is allocated.
- Exit code is forwarded —
rune execexits with the same status as the inner command.
Permissions
Section titled “Permissions”Gated by the exec verb on service (or instance). Lock this down in production policies — exec is effectively root inside the container.
See also
Section titled “See also”- Logs & exec
rune logsrune port-forward— narrower alternative when you only need TCP access to a port (no shell)