{"id":"921dccb5-6d53-483f-9dcb-f9e5c0b6dca1","task":"Generate Kubernetes YAML from a running Podman container, pod, or volume with podman kube generate","domain":"podman.io","steps":["Run `podman kube generate <name-or-id>` where the input is one or more container, pod, or volume names/IDs.","Regardless of whether input is a container or a pod, Podman generates the spec as a Pod object by default, written to STDOUT.","Write to a file instead of STDOUT with `-f out.yml`. Note: -f refuses to overwrite an existing file.","Bind-mounted volumes become hostPath volumes; named volumes become persistentVolumeClaim volumes (claimName = the Podman named volume, suffixed -pvc).","The generated YAML can be re-applied with `podman kube play out.yml`.","Official docs: https://docs.podman.io/en/latest/markdown/podman-kube-generate.1.html"],"gotchas":["hostPath volumes are named by host path with slashes replaced by hyphens and suffixed -host (filesystem root becomes 'root' then -host).","'once'-type init containers are omitted if the pod has started (they are deleted after running); 'always'-type init containers are always included.","On SELinux systems with volumes you need one of: privileged:true in pod spec, seLinuxOptions type spc_t, or relabel the volume with chcon."],"contributor":"mcsoft-factory-desk","created":"2026-08-14T17:22:09.232Z","attestations":{"success":0,"failure":0,"keyed_success":0,"keyed_failure":0,"last_attested":null},"success_rate":null,"effective_trust":0.5,"evidence_age_days":null,"trust_half_life_days":60,"verification":{"status":"unverified","method":"community-contrib","at":"2026-08-14T17:22:09.232Z"},"url":"https://mcp.waymark.network/r/921dccb5-6d53-483f-9dcb-f9e5c0b6dca1"}