# ____ _ __ __ _ _
# | _ \ ___ __| |_ __ ___ __ _ _ __ | \/ | __ _ ___| |__ (_)_ __ ___
# | |_) / _ \ / _` | '_ ` _ \ / _` | '_ \ | |\/| |/ _` |/ __| '_ \| | '_ \ / _ \
# | __/ (_) | (_| | | | | | | (_| | | | | | | | | (_| | (__| | | | | | | | __/
# |_| \___/ \__,_|_| |_| |_|\__,_|_| |_| |_| |_|\__,_|\___|_| |_|_|_| |_|\___|
[!attention] Podman Machine is not intended for Linux! Podman Machine is primarily intended for machines like windows to create an initial virtual environment suitable for podman to run in. It is not intended for use in linux.
Primarily podman is intended to be used to manage virtual containers, and this is what it does best. It is important to distinguish the difference between podman containers and podman machine. Podman relies on podman machine to run containers for operating systems that do not provide a native virtual abstraction layer. So, in effect, the two are two different layers of the same system that implement separate functionality of the virtual environment ecosystem. On Linux, Podman Machine is not implemented by default, and is not required for use of the podman ecosystem.
Podman Machine is the interface to the podman virtual machine layer, which is the fully virtualized environment podman uses to manage and run virtual containers on. For linux systems this feature is not required and is not implemented by default, and it’s primary application is intended for use with MacOS and Windows systems which do not provide virtual abstraction layer. Linux systems can access and use the podman virtual machine layer to perform other tasks. The benefit one recieves from using podman in this manner is access to peripheral devices that are not normally accessible to docker images. The default image used for doing this is fedora-core, but podman can be configured to use other OCI images.
To use this feature, simply initialize a new podman machine with:
podman machine init
Do not use sudo for this, as podman machines are not intended to be run as root ever.
In order for podman machine to run, the user will need to perform a few extra steps.
ls /usr/libexec/podman
and take note of the binary executables listed. There should be three symbolic
links to binary executables; catatonit, conmon, and gvproxy. There should also be two binary files; quadlet
and rootlessport.which $MISSING_FILE_GOES_HERE
, for example which gvproxy
. This command will
check if the file is in your path, and it should be. If this does not work and you have mlocate installed,
you could run sudo updatedb && locate $MISSING_FILE_GOES_HERE
.sudo apt install $MISSING_FILE_GOES_HERE
/usr/libexec/podman
.
This can be done quickly with sudo ln -sf $(which $MISSING_FILE_GOES_HERE) /usr/libexec/podman/$MISSING_FILE_GOES_HERE
.If you would like to add a USB device along with this new image you can use:
podman machine set --usb vendor=XXX,product=XXX
# OR
podman machine set --usb bus=XXX,devnum=XXX
Using bus and id are also accepted for these values, although they will change if the device is moved to a different usb port or another usb is removed.
If you need your podman machine to have root permissions, you can run: podman machine set --rootful
.