add task to auto-run update task if status is before/after
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
parent
cd80189608
commit
1e789c6642
@ -1,4 +1,5 @@
|
|||||||
---
|
---
|
||||||
|
- block:
|
||||||
- name: Set pam module configuration
|
- name: Set pam module configuration
|
||||||
pamd:
|
pamd:
|
||||||
name: "{{ item.name | default('system-auth') }}"
|
name: "{{ item.name | default('system-auth') }}"
|
||||||
@ -11,5 +12,16 @@
|
|||||||
state: "{{ item.state | default('args_present') }}"
|
state: "{{ item.state | default('args_present') }}"
|
||||||
module_arguments: "{{ item.module_arguments | default(omit) }}"
|
module_arguments: "{{ item.module_arguments | default(omit) }}"
|
||||||
loop: "{{ pam_settings + pam_settings_extra }}"
|
loop: "{{ pam_settings + pam_settings_extra }}"
|
||||||
|
|
||||||
|
- name: Auto-update items with state: before/after
|
||||||
|
pamd:
|
||||||
|
name: "{{ item.name | default('system-auth') }}"
|
||||||
|
type: "{{ item.new_type }}"
|
||||||
|
module_path: "{{ item.new_module_path }}"
|
||||||
|
control: "{{ item.new_control }}"
|
||||||
|
state: updated
|
||||||
|
module_arguments: "{{ item.module_arguments | default(omit) }}"
|
||||||
|
loop: "{{ pam_settings + pam_settings_extra }}"
|
||||||
|
when: item.state == "before" or item.state == "after"
|
||||||
become: True
|
become: True
|
||||||
become_user: root
|
become_user: root
|
||||||
|
Loading…
Reference in New Issue
Block a user