containers.podman.podman_pod_info – Gather info about podman pods

Note

This plugin is part of the containers.podman collection (version 1.5.0).

To install it use: ansible-galaxy collection install containers.podman.

To use it in a playbook, specify: containers.podman.podman_pod_info.

New in version 1.0.0: of containers.podman

Synopsis

  • Gather info about podman pods with podman inspect command.

Requirements

The below requirements are needed on the host that executes this module.

  • Podman installed on host

Parameters

Parameter Choices/Defaults Comments
executable
string
Default:
"podman"
Path to podman executable if it is not in the $PATH on the machine running podman
name
string
Name of the pod

Examples

- name: Gather info about all present pods
  containers.podman.podman_pod_info:

- name: Gather info about specific pods
  containers.podman.podman_pod_info:
    name: special_pod

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key Returned Description
pods
list / elements=string
always
Facts from all or specified pods

Sample:
[{'Config': {'cgroupParent': '/libpod_parent', 'created': '2020-07-13T20:29:12.572282186+03:00', 'hostname': 'pod1host', 'id': 'd9cb6dbb0....', 'infraConfig': {'infraPortBindings': [{'containerPort': 7111, 'hostIP': '', 'hostPort': 7777, 'protocol': 'tcp'}], 'makeInfraContainer': True}, 'labels': {}, 'lockID': 682, 'name': 'pod1', 'sharesCgroup': True, 'sharesIpc': True, 'sharesNet': True, 'sharesUts': True}, 'Containers': [{'id': 'ad46737bf....', 'state': 'configured'}], 'State': {'cgroupPath': '/libpod_parent/d9cb6dbb0....', 'infraContainerID': 'ad46737bf....', 'status': 'Created'}}]


Authors

  • Sagi Shnaidman (@sshnaidm)