Skip to content

Commit

Permalink
Move installation of debian php-pgsql
Browse files Browse the repository at this point in the history
There is a corresponding php-mysql package, and we might aswell
make sure that is installed based on zabbix_server_database.
  • Loading branch information
eb4x committed Jun 9, 2024
1 parent 7569780 commit 07dd401
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 19 deletions.
18 changes: 0 additions & 18 deletions roles/zabbix_web/tasks/Debian.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,3 @@
zabbix_underscore_version: "{{ zabbix_web_version | regex_replace('\\.', '_') }}"
tags:
- always

- name: "Debian | Install PgSQL Dependencies"
ansible.builtin.apt:
pkg: "php{{ zabbix_web_php_installed_version }}-pgsql"
state: "present"
update_cache: true
cache_valid_time: 0
environment:
http_proxy: "{{ zabbix_http_proxy | default(None) | default(omit) }}"
https_proxy: "{{ zabbix_https_proxy | default(None) | default(omit) }}"
register: zabbix_web_php_dependencies_install
until: zabbix_web_php_dependencies_install is succeeded
become: true
when: zabbix_server_database == 'pgsql'
tags:
- install
- dependencies
- database
2 changes: 2 additions & 0 deletions roles/zabbix_web/tasks/apache.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@
become: true
tags:
- install
- dependencies
- database

- name: "Apache | Get Apache version"
ansible.builtin.shell: |
Expand Down
4 changes: 3 additions & 1 deletion roles/zabbix_web/vars/Debian.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ _zabbix_web_apache_packages:
- zabbix-apache-conf
_zabbix_web_apache_php_dependencies:
- "libapache2-mod-php{{ zabbix_web_php_installed_version }}"
- "php{{ zabbix_web_php_installed_version }}-{{ zabbix_server_database }}"
_zabbix_web_nginx_package:
- zabbix-nginx-conf
_zabbix_web_nginx_php_dependencies: []
_zabbix_web_nginx_php_dependencies:
- "php{{ zabbix_web_php_installed_version }}-{{ zabbix_server_database }}"

0 comments on commit 07dd401

Please sign in to comment.