Build an image

Build an image from a Containerfile, which uses the same format as a Dockerfile

podman build -t myapp:latest -f Containerfile .

tool
podman16 commands
tags
podmancontainers

More podman commands

  • podman generate systemd --new --name web > ~/.config/systemd/user/web.service

    Create a systemd user unit that starts, stops and restarts the container

  • podman play kube deployment.yaml

    Run a pod from a Kubernetes manifest on your machine, handy for local tests

  • podman generate kube mypod > pod.yaml

    Generate a Kubernetes manifest from a running pod

  • podman pod create --name mypod -p 8080:80 && podman run -d --pod mypod nginx:alpine

    Put containers into one pod so they share the same network namespace

  • podman image inspect myapp:latest | jq '.[0].RootFS.Layers'

    List the filesystem layers of an image

all 16 podman commands