mirror of
https://github.com/freeipa/ansible-freeipa.git
synced 2026-07-30 19:34:45 +00:00
ipasudocmdgroup: Remove unused sudocmdgroup.
Remove an unused attribute that has no parallel in IPA API.
This commit is contained in:
@@ -50,10 +50,6 @@ options:
|
|||||||
description: Suppress processing of membership attributes
|
description: Suppress processing of membership attributes
|
||||||
required: false
|
required: false
|
||||||
type: bool
|
type: bool
|
||||||
sudocmdgroup:
|
|
||||||
description: List of sudocmdgroup names assigned to this sudocmdgroup.
|
|
||||||
required: false
|
|
||||||
type: list
|
|
||||||
sudocmd:
|
sudocmd:
|
||||||
description: List of sudocmds assigned to this sudocmdgroup.
|
description: List of sudocmds assigned to this sudocmdgroup.
|
||||||
required: false
|
required: false
|
||||||
@@ -157,7 +153,6 @@ def main():
|
|||||||
# present
|
# present
|
||||||
description=dict(type="str", default=None),
|
description=dict(type="str", default=None),
|
||||||
nomembers=dict(required=False, type='bool', default=None),
|
nomembers=dict(required=False, type='bool', default=None),
|
||||||
sudocmdgroup=dict(required=False, type='list', default=None),
|
|
||||||
sudocmd=dict(required=False, type='list', default=None),
|
sudocmd=dict(required=False, type='list', default=None),
|
||||||
action=dict(type="str", default="sudocmdgroup",
|
action=dict(type="str", default="sudocmdgroup",
|
||||||
choices=["member", "sudocmdgroup"]),
|
choices=["member", "sudocmdgroup"]),
|
||||||
@@ -180,7 +175,6 @@ def main():
|
|||||||
# present
|
# present
|
||||||
description = ansible_module.params.get("description")
|
description = ansible_module.params.get("description")
|
||||||
nomembers = ansible_module.params.get("nomembers")
|
nomembers = ansible_module.params.get("nomembers")
|
||||||
sudocmdgroup = ansible_module.params.get("sudocmdgroup")
|
|
||||||
sudocmd = ansible_module.params.get("sudocmd")
|
sudocmd = ansible_module.params.get("sudocmd")
|
||||||
action = ansible_module.params.get("action")
|
action = ansible_module.params.get("action")
|
||||||
# state
|
# state
|
||||||
|
|||||||
@@ -75,17 +75,12 @@
|
|||||||
failed_when: result.changed
|
failed_when: result.changed
|
||||||
|
|
||||||
- name: Verify sudocmdgroup creation with sudocmds
|
- name: Verify sudocmdgroup creation with sudocmds
|
||||||
block:
|
shell: |
|
||||||
- name: Get Kerberos ticket for `admin`.
|
echo SomeADMINpassword | kinit -c verify_sudocmdgroup admin
|
||||||
shell: echo SomeADMINpassword | kinit -c test_sudocmdgroup_krb5ccname admin
|
KRB5CCNAME="verify_sudocmdgroup" ipa sudocmdgroup-show network --all
|
||||||
|
kdestroy -A -q -c verify_sudocmdgroup
|
||||||
- name: Check sudocmdgroup-show output.
|
register: result
|
||||||
shell: ipa sudocmdgroup-show network --all
|
failed_when: result.failed or not("/usr/sbin/ifconfig" in result.stdout and "/usr/sbin/iwlist" in result.stdout)
|
||||||
register: result
|
|
||||||
failed_when: result.failed or not("/usr/sbin/ifconfig" in result.stdout and "/usr/sbin/iwlist" in result.stdout)
|
|
||||||
|
|
||||||
- name: Destroy Kerberos tickets.
|
|
||||||
shell: kdestroy -A -q -c test_sudocmdgroup_krb5ccname
|
|
||||||
|
|
||||||
- name: Ensure sudocmdgroup, with sudocmds, is absent
|
- name: Ensure sudocmdgroup, with sudocmds, is absent
|
||||||
ipasudocmdgroup:
|
ipasudocmdgroup:
|
||||||
|
|||||||
Reference in New Issue
Block a user