mirror of
https://github.com/tldr-pages/tldr.git
synced 2026-11-06 00:52:51 +08:00
Co-authored-by: Managor <42655600+Managor@users.noreply.github.com>
1000 B
1000 B
podman commit
Create a new image based on the changed container. More information: https://docs.podman.io/en/latest/markdown/podman-commit.1.html.
- Create an image from a specific container:
podman commit {{container}} {{image}}:{{tag}}
- Apply an
ENVinstruction to the created image:
podman commit {{[-c|--change]}} "ENV {{name}}={{value}}" {{container}} {{image}}:{{tag}}
- Apply
LABEL,ENTRYPOINT, andCMDinstruction to the created image:
podman commit {{[-c|--change]}} CMD={{command}} {{[-c|--change]}} ENTRYPOINT={{command}} {{[-c|--change]}} "LABEL {{key}}={{value}}" {{container}} {{image}}:{{tag}}
- Create an image with a specific author and comment in the metadata:
podman commit {{[-a|--author]}} "{{author}}" {{[-m|--message]}} "{{comment}}" {{container}} {{image}}:{{tag}}
- Create an image without pausing the container during commit:
podman commit {{[-p|--pause]}} false {{container}} {{image}}:{{tag}}
- Display help:
podman commit --help