Skip to content

Commit e75fae6

Browse files
committed
skip dashboard installation in configure mode
1 parent b0640a2 commit e75fae6

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

ansible/monitoring.yml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -80,19 +80,18 @@
8080
hosts: grafana
8181
tags: grafana
8282
tasks:
83-
- assert:
84-
that: vault_grafana_admin_password is defined
85-
fail_msg: "Must define vault_grafana_admin_password - use `ansible-playbook generate-passwords.yml` to generate a set of passwords"
83+
- name: Skip plugin installation in configure mode
84+
# done during fatimage - can't do this in vars block as that is recursive
85+
ansible.builtin.set_fact:
86+
grafana_plugins: "{{ [] if appliances_mode == 'configure' else grafana_plugins }}"
8687
- include_role:
8788
name: cloudalchemy.grafana
8889
vars:
89-
# Plugin installation done during fatimage:
90-
grafana_plugins: "{{ if appliances_mode == 'configure' else grafana_plugins }}"
9190
# Internal role used to install dashboards as cloudalchemy role does not support all required options:
9291
grafana_dashboards: []
9392
- include_role: # done in same play so it can use handlers from cloudalchemy.grafana
9493
name: grafana-dashboards
95-
when: "{{ appliances_mode != 'configure '}}"
94+
when: "appliances_mode != 'configure'"
9695

9796
- name: Deploy alertmanager
9897
hosts: alertmanager

0 commit comments

Comments
 (0)