Skip to content

Commit

Permalink
yoda_zabbix_database: adapt for EL8
Browse files Browse the repository at this point in the history
We need to have a version of libzbxpgsql.so with a binary patch to
work around a compatibility issue with Zabbix 4. See
zabbix-tools/libzbxpgsql#139 (comment)
for details.
  • Loading branch information
stsnel committed May 11, 2023
1 parent 5d7dc16 commit b71802b
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 8 deletions.
7 changes: 0 additions & 7 deletions roles/yoda_zabbix_database/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,6 @@
# Temporary directory to store downloaded rpm files.
rpm_dest_dir: /tmp

# Zabbix postgres rpm location and checksum
zabbix_postgres:
package: libzbxpgsql-1.1.0-1
url: https://github.com/UtrechtUniversity/yoda-zabbix/releases/download/1.3-beta/
filename: libzbxpgsql-1.1.0-1.el7.x86_64.rpm
checksum: sha256:b6e7051bb41aceec9edfaa20189e83ab5403ae4cd8d5b67bfffe20f30d93fb23

# Zabbix postgres database user (CREATE ROLE zabbix WITH LOGIN NOSUPERUSER, NOCREATEDB, NOCREATEROLE
# and (GRANT CONNECT ON DATABASE "ICAT" TO zabbix)
# Zabbix configuration
Expand Down
7 changes: 6 additions & 1 deletion roles/yoda_zabbix_database/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
---
# copyright Utrecht University

- name: Include distribution version specific variables for Zabbix
ansible.builtin.include_vars: "rh{{ ansible_distribution_major_version }}.yml"


- name: Check if Zabbix PostgreSQL monitoring RPM is installable from repository
ansible.builtin.yum:
list: '{{ zabbix_postgres.package }}'
Expand All @@ -18,9 +22,10 @@


- name: Install Zabbix PostgreSQL monitoring from downloaded RPM
ansible.builtin.package:
ansible.builtin.yum:
name: '{{ rpm_dest_dir }}/{{ zabbix_postgres.filename }}'
state: present
disable_gpg_check: true
when: not zabbix_postgres_repo.results and not repo_only


Expand Down
9 changes: 9 additions & 0 deletions roles/yoda_zabbix_database/vars/rh7.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
# copyright Utrecht University

# Zabbix postgres rpm location and checksum
zabbix_postgres:
package: libzbxpgsql-1.1.0-1
url: https://github.com/UtrechtUniversity/yoda-zabbix/releases/download/1.3-beta/
filename: libzbxpgsql-1.1.0-1.el7.x86_64.rpm
checksum: sha256:b6e7051bb41aceec9edfaa20189e83ab5403ae4cd8d5b67bfffe20f30d93fb23
9 changes: 9 additions & 0 deletions roles/yoda_zabbix_database/vars/rh8.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
# copyright Utrecht University

# Zabbix postgres rpm location and checksum
zabbix_postgres:
package: libzbxpgsql-1.1.0-rh8
url: https://github.com/UtrechtUniversity/yoda-zabbix/releases/download/1.3-beta/
filename: libzbxpgsql-1.1.0-rh8.x86_64.rpm
checksum: sha256:123f1e95264339959e5ebff758eea6f224dd381f4479aa7760e9408346ca19c1

0 comments on commit b71802b

Please sign in to comment.