Note
This plugin is part of the community.general collection.
To install it use: ansible-galaxy collection install community.general
.
To use it in a playbook, specify: community.general.docker_stack_task_info
.
New in version 1.1.0: of community.general
docker stack
command on the target node (see examples).Parameter | Choices/Defaults | Comments |
---|---|---|
name string / required | Stack name. |
- name: Shows stack info community.general.docker_stack_task_info: name: test_stack register: result - name: Show results ansible.builtin.debug: var: result.results
Common return values are documented here, the following are the fields unique to this module:
Key | Returned | Description |
---|---|---|
results list / elements=dictionary | always | List of dictionaries containing the list of tasks associated to a stack name. Sample: [{"CurrentState":"Running","DesiredState":"Running","Error":"","ID":"7wqv6m02ugkw","Image":"busybox","Name":"test_stack.1","Node":"swarm","Ports":""}] |
© 2012–2018 Michael DeHaan
© 2018–2019 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/2.10/collections/community/general/docker_stack_task_info_module.html