Merge pull request #426 from exploide/firewalld_info_docs

firewalld_info: fixed typo in default_zone and improved examples

SUMMARY
There was a typo in the docs of firewalld_info. Furthermore I slightly improved the examples by showcasing how to use the data gathered by this module.
ISSUE TYPE


Docs Pull Request

COMPONENT NAME

firewalld_info
ADDITIONAL INFORMATION
I'm not sure whether I should also update the file docs/ansible.posix.firewalld_info_module.rst but I suspect it will be generated automatically?

Reviewed-by: Hideki Saito <saito@fgrep.org>
This commit is contained in:
softwarefactory-project-zuul[bot] 2023-03-24 06:51:24 +00:00 committed by GitHub
commit f47c5d6039
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 1 deletions

View file

@ -0,0 +1,4 @@
---
trivial:
- firewalld_info - fixed typo in return value and improved examples in documentation

View file

@ -37,6 +37,11 @@ EXAMPLES = r'''
- name: Gather information about active zones - name: Gather information about active zones
ansible.posix.firewalld_info: ansible.posix.firewalld_info:
active_zones: true active_zones: true
register: result
- name: Print default zone for debugging
ansible.builtin.debug:
var: result.firewalld_info.default_zone
- name: Gather information about specific zones - name: Gather information about specific zones
ansible.posix.firewalld_info: ansible.posix.firewalld_info:
@ -44,6 +49,7 @@ EXAMPLES = r'''
- public - public
- external - external
- internal - internal
register: result
''' '''
RETURN = r''' RETURN = r'''
@ -78,7 +84,7 @@ firewalld_info:
returned: success returned: success
type: str type: str
sample: 0.8.2 sample: 0.8.2
default_zones: default_zone:
description: description:
- The zone name of default zone. - The zone name of default zone.
returned: success returned: success