forked from ceph/ceph-ansible
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ceph-infra: move dashboard into a dedicated file
Instead of using multiple dashboard_enabled condition in the configure_firewall file we could just have the condition once and include the dedicated tasks list. Signed-off-by: Dimitri Savineau <[email protected]>
- Loading branch information
Showing
2 changed files
with
57 additions
and
57 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
--- | ||
- name: open node_exporter port | ||
firewalld: | ||
port: "{{ node_exporter_port }}/tcp" | ||
zone: "{{ ceph_dashboard_firewall_zone }}" | ||
permanent: true | ||
immediate: true | ||
state: enabled | ||
|
||
- block: | ||
- name: open dashboard port | ||
firewalld: | ||
port: "{{ dashboard_port }}/tcp" | ||
zone: "{{ ceph_dashboard_firewall_zone }}" | ||
permanent: true | ||
immediate: true | ||
state: enabled | ||
|
||
- name: open mgr/prometheus port | ||
firewalld: | ||
port: "9283/tcp" | ||
zone: "{{ ceph_dashboard_firewall_zone }}" | ||
permanent: true | ||
immediate: true | ||
state: enabled | ||
when: | ||
- mgr_group_name is defined | ||
- (groups.get(mgr_group_name,[]) | length > 0 and mgr_group_name in group_names) or | ||
(groups.get(mgr_group_name,[]) | length == 0 and mon_group_name in group_names) | ||
|
||
- block: | ||
- name: open grafana port | ||
firewalld: | ||
port: "{{ grafana_port }}/tcp" | ||
zone: "{{ ceph_dashboard_firewall_zone }}" | ||
permanent: true | ||
immediate: true | ||
state: enabled | ||
|
||
- name: open prometheus port | ||
firewalld: | ||
port: "{{ prometheus_port }}/tcp" | ||
zone: "{{ ceph_dashboard_firewall_zone }}" | ||
permanent: true | ||
immediate: true | ||
state: enabled | ||
|
||
- name: open alertmanager port | ||
firewalld: | ||
port: "{{ alertmanager_port }}/tcp" | ||
zone: "{{ ceph_dashboard_firewall_zone }}" | ||
permanent: true | ||
immediate: true | ||
state: enabled | ||
when: inventory_hostname in groups.get('grafana-server', []) |