refactor firewalld module with object abstraction (#26487)
* refactor firewalld module with object abstraction This change creates a FirewallTransaction object that each individual transaction type is a sub-class of as they all follow the same pattern to enable or disable something in the firewall. Also, there's a few bugfixes here: - Fix the "source" type to handle permanent operations - Remove ambiguity of required parameters for only specific use cases that can lead to transactions effectively being a no-op. Instead, pick sane defaults and document them. - Change how imports are done so globals are no longer needed This is based on the original feedback by Toshio from the last refactor attempt: https://github.com/ansible/ansible-modules-extras/pull/3383 Signed-off-by: Adam Miller <maxamillion@fedoraproject.org> * fix line too long for pep8 for shippable tests Signed-off-by: Adam Miller <maxamillion@fedoraproject.org> * remove firewalld from pep8/legacy-files Signed-off-by: Adam Miller <maxamillion@fedoraproject.org>
This commit is contained in:
parent
869a318492
commit
75127092f2
2 changed files with 675 additions and 806 deletions
File diff suppressed because it is too large
Load diff
|
@ -425,7 +425,6 @@ lib/ansible/modules/system/crypttab.py
|
|||
lib/ansible/modules/system/debconf.py
|
||||
lib/ansible/modules/system/facter.py
|
||||
lib/ansible/modules/system/filesystem.py
|
||||
lib/ansible/modules/system/firewalld.py
|
||||
lib/ansible/modules/system/gconftool2.py
|
||||
lib/ansible/modules/system/getent.py
|
||||
lib/ansible/modules/system/gluster_volume.py
|
||||
|
|
Loading…
Reference in a new issue