From f5475063e647b545e187a536b7bcb30d1236205c Mon Sep 17 00:00:00 2001 From: Greg Sutcliffe Date: Fri, 4 Apr 2025 16:27:23 +0100 Subject: [PATCH] Zabbix-stg: disable user-management until we can upgrade to 3.3.0 --- roles/zabbix/zabbix_server/defaults/main.yml | 3 ++ .../zabbix_server/tasks/configure_api.yml | 51 ++++++++++--------- 2 files changed, 30 insertions(+), 24 deletions(-) diff --git a/roles/zabbix/zabbix_server/defaults/main.yml b/roles/zabbix/zabbix_server/defaults/main.yml index 0c0b7852a8..c71b8d6a47 100644 --- a/roles/zabbix/zabbix_server/defaults/main.yml +++ b/roles/zabbix/zabbix_server/defaults/main.yml @@ -8,6 +8,9 @@ zabbix_db_name: zabbix # OVERRIDE zabbix_db_user: zabbix # OVERRIDE zabbix_db_pass: zabbix # OVERRIDE +# This is to configure matching PSK identity to the agents +zabbix_tls_psk_identity: "Fedora" # OVERRIDE + zabbix_server_pkgs: - zabbix-server-pgsql - zabbix-web-pgsql diff --git a/roles/zabbix/zabbix_server/tasks/configure_api.yml b/roles/zabbix/zabbix_server/tasks/configure_api.yml index 39b7177f18..d13dbdd33f 100644 --- a/roles/zabbix/zabbix_server/tasks/configure_api.yml +++ b/roles/zabbix/zabbix_server/tasks/configure_api.yml @@ -65,30 +65,33 @@ - zabbix_configuration - zabbix_triggers - - name: Create a new Zabbix user for Matrix triggers - community.zabbix.zabbix_user: - username: matrix-bot - name: Matrix - surname: Bot - usrgrps: - - Zabbix administrators - passwd: "{{ (env == 'staging') | ternary(zabbix_stg_botuser_pwd, zabbix_botuser_pwd) }}" - user_medias: - - mediatype: Matrix - sendto: "{{ (env == 'staging') | ternary(zabbix_stg_matrix_roomid, zabbix_matrix_roomid) }}" - period: 1-7,00:00-24:00 - severity: - not_classified: yes - information: yes - warning: yes - average: yes - high: yes - disaster: yes - active: yes - state: present - tags: - - zabbix_configuration - - zabbix_users +# Breaks on second run with community.zabbix < 3.3.0 +# See https://github.com/ansible-collections/community.zabbix/commit/8a962bfc046353db60a594ddc259fae396fc20a9 +# Revisit after freeze is over - don't delete the user or the next task will fail +# - name: Create a new Zabbix user for Matrix triggers +# community.zabbix.zabbix_user: +# username: matrix-bot +# name: Matrix +# surname: Bot +# usrgrps: +# - Zabbix administrators +# passwd: "{{ (env == 'staging') | ternary(zabbix_stg_botuser_pwd, zabbix_botuser_pwd) }}" +# user_medias: +# - mediatype: Matrix +# sendto: "{{ (env == 'staging') | ternary(zabbix_stg_matrix_roomid, zabbix_matrix_roomid) }}" +# period: 1-7,00:00-24:00 +# severity: +# not_classified: yes +# information: yes +# warning: yes +# average: yes +# high: yes +# disaster: yes +# active: yes +# state: present +# tags: +# - zabbix_configuration +# - zabbix_users - name: Send alerts to Matrix community.zabbix.zabbix_action: