podman-machine-ssh(1)
π podman-machine-ssh(1) β bestie edition π
okay so we're doing the podman-machine-ssh page from the General Commands Manual and honestly? it's giving "let me just pop into my VM real quick" energy β¨
πΈ NAME πΈ
podman-machine-ssh β SSH into a virtual machine π₯οΈβ¨
π¦ SYNOPSIS π¦
podman machine ssh [options] [name] [command [arg ...]]
π DESCRIPTION π
So here's the tea, bestie: podman machine ssh SSHes you into a Podman-managed virtual machine, and if you want, it'll also run a command for you while it's in there. no cap π«Ά
Unless you're using the default virtual machine, the first argument has to be the virtual machine name. After that name, the optional command you wanna execute can follow. And if you don't hand it a command at all? You get a whole interactive session with the VM, main character style π
The exit code from the ssh command gets forwarded right back to the podman machine ssh caller β check Exit Codes β¨#Exit-Codesβ© for the deets.
The default machine name is podman-machine-default. So if you don't specify a machine name as an argument, then podman-machine-default is what you'll be SSH'd into. it's literally the default, that's the whole vibe π«
Rootless only. that's it, that's the note. π
β¨ OPTIONS β¨
--helpβ prints the usage statement. classic. iconic. we love a helper π--username=nameβ the username to use when SSH-ing into the VM π
π₯ Exit Codes π₯
The exit code from podman machine ssh tells you why the command failed β like a little vibe check for your errors. When podman machine ssh commands exit with a non-zero code, the exit codes follow the chroot standard, see below:
125 β the error is with podman itself π
$ podman machine ssh --foo; echo $?
Error: unknown flag: --foo
125
126 β executing a contained command and the command cannot be invoked π
$ podman machine ssh /etc; echo $?
Error: fork/exec /etc: permission denied
126
127 β executing a contained command and the command cannot be found π΅οΈ
$ podman machine ssh foo; echo $?
Error: fork/exec /usr/bin/bogus: no such file or directory
127
Exit code contained command exit code β whatever the command inside felt like returning, you get it back fr fr π
$ podman machine ssh /bin/sh -c 'exit 3'; echo $?
3
π EXAMPLES π
To get an interactive session with the default Podman machine:
SSH into the default Podman machine.
$ podman machine ssh
Run command inside the default Podman machine via ssh.
$ podman machine ssh myvm
Run command inside the specified Podman machine via ssh.
$ podman machine ssh myvm rpm -q podman
π SEE ALSO π
π HISTORY π
March 2021, Originally compiled by Ashley Cui acui@redhat.com β¨mailto:acui@redhat.comβ©
and that's the whole page, bestie!! mwah π this was podman-machine-ssh(1) from the General Commands Manual β go forth and SSH into ur VM like the icon u are π¦β¨π
π¦ where this page comes from
- arch rolling: podman-docker 6.1.4-1 Β· Apache-2.0
- fedora 43: podman-docker 5:5.6.2-1.fc43 Β· Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND ISC AND MIT AND MPL-2.0
- fedora 43: podman-docker 5:5.8.4-1.fc43
- fedora 43: podman-docker 5:5.8.8-1.fc43
- fedora 43: podman-docker 5:5.8.9-1.fc43 Β· Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND ISC AND MIT AND MPL-2.0
- fedora 44: podman-docker 5:5.8.1-1.fc44 Β· Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND ISC AND MIT AND MPL-2.0
- fedora 44: podman-docker 5:5.8.7-1.fc44
- fedora 44: podman-docker 5:5.8.9-1.fc44 Β· Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND ISC AND MIT AND MPL-2.0
- ubuntu resolute: podman-docker 5.7.0+ds2-3build1 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms