[PR #9421/2a2a9661 backport][stable-10] [ab]*.py: normalize docs (#9427)

[ab]*.py: normalize docs (#9421)

* [ab]*.py: normalize docs

* Update plugins/modules/atomic_image.py

Co-authored-by: Felix Fontein <felix@fontein.de>

---------

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 2a2a9661d9)

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
This commit is contained in:
patchback[bot] 2024-12-27 14:52:29 +01:00 committed by GitHub
parent 3db0a11148
commit 14038511a1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
36 changed files with 1931 additions and 2013 deletions

View file

@ -9,69 +9,67 @@ from __future__ import absolute_import, division, print_function
__metaclass__ = type
DOCUMENTATION = r'''
---
DOCUMENTATION = r"""
module: atomic_container
short_description: Manage the containers on the atomic host platform
description:
- Manage the containers on the atomic host platform.
- Allows to manage the lifecycle of a container on the atomic host platform.
- Manage the containers on the atomic host platform.
- Allows to manage the lifecycle of a container on the atomic host platform.
author: "Giuseppe Scrivano (@giuseppe)"
notes:
- Host should support C(atomic) command
requirements:
- atomic
- atomic
notes:
- According to U(https://projectatomic.io/) the project has been sunset around 2019/2020, in favor of C(podman) and Fedora CoreOS.
extends_documentation_fragment:
- community.general.attributes
- community.general.attributes
attributes:
check_mode:
support: none
diff_mode:
support: none
options:
backend:
description:
- Define the backend to use for the container.
required: true
choices: ["docker", "ostree"]
type: str
name:
description:
- Name of the container.
required: true
type: str
image:
description:
- The image to use to install the container.
required: true
type: str
rootfs:
description:
- Define the rootfs of the image.
type: str
state:
description:
- State of the container.
choices: ["absent", "latest", "present", "rollback"]
default: "latest"
type: str
mode:
description:
- Define if it is an user or a system container.
choices: ["user", "system"]
type: str
values:
description:
- Values for the installation of the container.
- This option is permitted only with mode 'user' or 'system'.
- The values specified here will be used at installation time as --set arguments for atomic install.
type: list
elements: str
default: []
'''
EXAMPLES = r'''
backend:
description:
- Define the backend to use for the container.
required: true
choices: ["docker", "ostree"]
type: str
name:
description:
- Name of the container.
required: true
type: str
image:
description:
- The image to use to install the container.
required: true
type: str
rootfs:
description:
- Define the rootfs of the image.
type: str
state:
description:
- State of the container.
choices: ["absent", "latest", "present", "rollback"]
default: "latest"
type: str
mode:
description:
- Define if it is an user or a system container.
choices: ["user", "system"]
type: str
values:
description:
- Values for the installation of the container.
- This option is permitted only with mode 'user' or 'system'.
- The values specified here will be used at installation time as --set arguments for atomic install.
type: list
elements: str
default: []
"""
EXAMPLES = r"""
- name: Install the etcd system container
community.general.atomic_container:
name: etcd
@ -80,7 +78,7 @@ EXAMPLES = r'''
state: latest
mode: system
values:
- ETCD_NAME=etcd.server
- ETCD_NAME=etcd.server
- name: Uninstall the etcd system container
community.general.atomic_container:
@ -89,15 +87,15 @@ EXAMPLES = r'''
backend: ostree
state: absent
mode: system
'''
"""
RETURN = r'''
RETURN = r"""
msg:
description: The command standard output
returned: always
type: str
sample: 'Using default tag: latest ...'
'''
description: The command standard output.
returned: always
type: str
sample: 'Using default tag: latest ...'
"""
# import module snippets
import traceback