Podman
Basics
CheckList thelocal image storageimages
podman images
Start a container based on an image ID. Get the ID from docker images.
podman run -it <your-image-id>run --name apache bitnami/apache
control-c will stop the container for all of the run commands.
Start an image based on a tag
podman run -it <image tag>
Start hello-world server
podman run -it-name quay.io/practicalopenshift/hello-worldapache bitnami/apache:2.4.52
Start the an app with port forwarding
podman run -it -p 8080:8080 quay.io/practicalopenshift/hello-world
Stopping Containers
Get running images
podman ps
Get all images
podman ps -a
Check container logs
podman logs <Container Name>
podman logs -f <Container Name> # Follow the logs
podman logs --tail=25 <Container Name> # Last n lines
Stop a running image. The container ID will be in the podman ps
output.
podman kill <Container ID>
Remove an image. The container ID will be in the podman ps
output.
podman rm <Container ID>
Remove all images.
podman rmi --all