From 855227c892a0896badd4572581fa77aa354d416a Mon Sep 17 00:00:00 2001 From: "patchback[bot]" <45432694+patchback[bot]@users.noreply.github.com> Date: Thu, 4 Aug 2022 14:33:10 +0200 Subject: [PATCH] Fix docs. (#436) (#437) (cherry picked from commit bc6757d3b8c6f20b4625ae9dce6c924094e7c2ec) Co-authored-by: Felix Fontein --- plugins/modules/docker_network_info.py | 4 ++-- plugins/modules/docker_prune.py | 16 ++++++++-------- plugins/modules/docker_stack_info.py | 5 +++-- plugins/modules/docker_swarm.py | 2 +- 4 files changed, 14 insertions(+), 13 deletions(-) diff --git a/plugins/modules/docker_network_info.py b/plugins/modules/docker_network_info.py index 7e4c10d0..2ec16284 100644 --- a/plugins/modules/docker_network_info.py +++ b/plugins/modules/docker_network_info.py @@ -68,7 +68,7 @@ network: - Will be C(none) if network does not exist. returned: always type: dict - sample: '{ + sample: { "Attachable": false, "ConfigFrom": { "Network": "" @@ -95,7 +95,7 @@ network: "Name": "ansible-test-f2700bba", "Options": {}, "Scope": "local" - }' + } ''' import traceback diff --git a/plugins/modules/docker_prune.py b/plugins/modules/docker_prune.py index aa29efd6..71b88637 100644 --- a/plugins/modules/docker_prune.py +++ b/plugins/modules/docker_prune.py @@ -120,13 +120,13 @@ containers: returned: I(containers) is C(true) type: list elements: str - sample: '[]' + sample: [] containers_space_reclaimed: description: - Amount of reclaimed disk space from container pruning in bytes. returned: I(containers) is C(true) type: int - sample: '0' + sample: 0 # images images: @@ -135,13 +135,13 @@ images: returned: I(images) is C(true) type: list elements: str - sample: '[]' + sample: [] images_space_reclaimed: description: - Amount of reclaimed disk space from image pruning in bytes. returned: I(images) is C(true) type: int - sample: '0' + sample: 0 # networks networks: @@ -150,7 +150,7 @@ networks: returned: I(networks) is C(true) type: list elements: str - sample: '[]' + sample: [] # volumes volumes: @@ -159,13 +159,13 @@ volumes: returned: I(volumes) is C(true) type: list elements: str - sample: '[]' + sample: [] volumes_space_reclaimed: description: - Amount of reclaimed disk space from volumes pruning in bytes. returned: I(volumes) is C(true) type: int - sample: '0' + sample: 0 # builder_cache builder_cache_space_reclaimed: @@ -173,7 +173,7 @@ builder_cache_space_reclaimed: - Amount of reclaimed disk space from builder cache pruning in bytes. returned: I(builder_cache) is C(true) type: int - sample: '0' + sample: 0 ''' import traceback diff --git a/plugins/modules/docker_stack_info.py b/plugins/modules/docker_stack_info.py index ef588c53..7741047e 100644 --- a/plugins/modules/docker_stack_info.py +++ b/plugins/modules/docker_stack_info.py @@ -23,10 +23,11 @@ results: description: | List of dictionaries containing the list of stacks or tasks associated to a stack name. - sample: > - "results": [{"name":"grafana","namespace":"default","orchestrator":"Kubernetes","services":"2"}] + sample: + - {"name":"grafana","namespace":"default","orchestrator":"Kubernetes","services":"2"} returned: always type: list + elements: dict ''' EXAMPLES = ''' diff --git a/plugins/modules/docker_swarm.py b/plugins/modules/docker_swarm.py index 43088af0..a78f533e 100644 --- a/plugins/modules/docker_swarm.py +++ b/plugins/modules/docker_swarm.py @@ -276,7 +276,7 @@ actions: returned: when action failed. type: list elements: str - example: "['This cluster is already a swarm cluster']" + example: ['This cluster is already a swarm cluster'] '''