containers.podman.podman_import module – Import Podman container from a tar file.
Note
This module is part of the containers.podman collection (version 1.16.2).
You might already have this collection installed if you are using the ansible
package.
It is not included in ansible-core
.
To check whether it is installed, run ansible-galaxy collection list
.
To install it, use: ansible-galaxy collection install containers.podman
.
You need further requirements to be able to use this module,
see Requirements for details.
To use it in a playbook, specify: containers.podman.podman_import
.
Synopsis
podman import imports a tarball (.tar, .tar.gz, .tgz, .bzip, .tar.xz, .txz) and saves it as a filesystem image.
Requirements
The below requirements are needed on the host that executes this module.
Podman installed on host
Parameters
Parameter |
Comments |
---|---|
Set changes as list of key-value pairs, see example. |
|
Set commit message for imported image |
|
Path to Default: |
|
Path to image file to load. |
|
Volume to import, cannot be used with change and commit_message |
Examples
# What modules does for example
- containers.podman.podman_import:
src: /path/to/tar/file
change:
- "CMD": /bin/bash
- "User": root
commit_message: "Importing image"
- containers.podman.podman_import:
src: /path/to/tar/file
volume: myvolume
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
---|---|
info from loaded image Returned: always Sample: |