Setup Podman on macOS
Podman is a utility that can be used to create and maintain containers. This post will teach you how to set up Podman on macOS and perform some basic commands.
Preparation
Homebrew
Install Homebrew:
bash 5
Install via Homebrew:
Podman
Install via Homebrew:
Podman Machine
Create and start your first Podman machine (2 CPUs, 100GB disk, 4GB memory). Podman machines are backed by QEMU. This will become the default Podman machine:
List all machines:
NAME VM TYPE CREATED LAST UP CPUS MEMORY DISK SIZE
podman-machine-default* qemu About a minute ago About a minute ago 2 4.295GB 107.4GB
Start the default machine:
Verify the installation:
The machine will be configured in rootless mode. If your containers require root permissions (e.g. ports < 1024), or if you run into compatibility issues with non-podman clients, you can switch using the following command:
Test
Run the Hello World
container:
Podman Desktop
To start a podman machine automatically at login, also install the Podman Desktop: