Podman
Image
List all images:
podman image ls
Delete all images:
podman image rm --all
Containers
List all containers:
podman ps --all
Stop a container:
podman stop kbsoftware-couk-kbsoftware-couk
Delete all containers:
podman rm --all
Run a command in the container:
podman exec -it kbsoftware-couk-kbsoftware-couk django-admin shell
Run a command in a new instance of the container:
podman run --rm -it 1022c5b2b083 ls -l /app/.venv/lib/python3.13/site-packages
Warning
run
will not use the environment variables setup
in the .yaml
file.
Tip
run
creates a new container and runs the command.
-rm
will delete the container after.
Pod
List:
podman pod ls
Run a pod from a yaml
file:
podman kube play kbsoftware-couk.yaml
Tip
Remember to update the image
in the yaml
file.
Remove a pod:
podman pod rm kbsoftware-couk
Shortcuts:
podman pod stop kbsoftware-couk; and podman pod rm kbsoftware-couk
podman kube play kbsoftware-couk.yaml --configmap=./config-map.yaml; and podman pod logs -f kbsoftware-couk