Skip to main content

Usage

phala ssh [cvm-id] [options] [-- ssh-options]

Arguments

NameRequiredDescription
cvm-idNoCVM ID, UUID, or name (uses linked CVM if omitted)

Options

FlagShortDefaultDescription
--port <port>-p443Gateway port (priority: CLI > phala.toml > 443)
--gateway <domain>-gGateway domain (priority: CLI > phala.toml > API)
--timeout <seconds>-t30Connection timeout
--verbose-vfalseShow verbose connection details
--dry-runfalsePrint SSH command without executing

Pass-through Options

All arguments after -- are passed directly to ssh. Trailing arguments are executed as remote commands. Common pass-through options:
  • -i — SSH identity file
  • -L — Local port forwarding
  • -R — Remote port forwarding
  • -D — SOCKS proxy
  • -N — No command (useful with port forwarding)
  • -v — SSH verbose mode
Note: -o ProxyCommand is blocked for security reasons.

Examples

Connect to linked CVM:
$ phala ssh
Connect to specific CVM:
$ phala ssh app_abc123
Forward local port 8080 to remote port 80:
$ phala ssh -- -L 8080:localhost:80
Execute remote command:
$ phala ssh -- ls /app
Print SSH command without executing:
$ phala ssh --dry-run
Connect with verbose details:
$ phala ssh --verbose
Use custom SSH identity:
$ phala ssh -- -i ~/.ssh/custom_key
Set up SOCKS proxy on port 1080:
$ phala ssh -- -D 1080 -N