You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This adds handlers to the 'icingaweb2' role to take care of Icinga
Director schema migrations and its kickstart. Running multiple roles in
order should also run their handlers in order. This way the Icinga 2 API
should be up and operational for the Director to use for kickstart.
Fixes#319
Copy file name to clipboardExpand all lines: roles/icingaweb2/tasks/modules/director.yml
+2-11Lines changed: 2 additions & 11 deletions
Original file line number
Diff line number
Diff line change
@@ -25,12 +25,7 @@
25
25
register: _pending
26
26
changed_when: _pending.rc|int == 0
27
27
failed_when: _pending.stdout|length > 0
28
-
when: icingaweb2_modules['director']['import_schema'] is defined and icingaweb2_modules.director.import_schema and icingaweb2_modules['director']['config'] is defined
when: icingaweb2_modules['director']['import_schema'] is defined and icingaweb2_modules.director.import_schema and icingaweb2_modules['director']['config'] is defined and _pending.rc|int == 0
28
+
notify: "run_director_migrations"
34
29
35
30
- name: Module Director | Check if kickstart is required # noqa: command-instead-of-shell
36
31
ansible.builtin.shell:
@@ -39,11 +34,7 @@
39
34
changed_when: _required.rc|int == 0
40
35
failed_when: _required.rc|int >= 2
41
36
when: icingaweb2_modules['director']['run_kickstart'] is defined and icingaweb2_modules.director.run_kickstart and icingaweb2_modules['director']['kickstart'] is defined
42
-
43
-
- name: Module Director | Run kickstart if required # noqa: command-instead-of-shell
44
-
ansible.builtin.shell:
45
-
cmd: icingacli director kickstart run
46
-
when: icingaweb2_modules['director']['run_kickstart'] is defined and icingaweb2_modules.director.run_kickstart and icingaweb2_modules['director']['kickstart'] is defined and _required.rc|int == 0
37
+
notify: "run_director_kickstart"
47
38
48
39
- name: Module Director | Ensure installation from source is complete
0 commit comments