Almalinux validé

This commit is contained in:
stef
2026-02-18 21:25:00 +00:00
parent 7c8f30ce06
commit 28799357f3
11 changed files with 352 additions and 37 deletions

View File

@@ -8,22 +8,17 @@
tags:
- install_db
- name: Database - Check if postgrsql configured
- name: Database - Check if postgresql is configured
stat:
path: /var/lib/pgsql/data
path: /var/lib/pgsql/data/PG_VERSION
register: postgresqldata
- name: Database - debug
debug:
var: postgresqldata
- name: Database - Init DB
ansible.builtin.shell:
cmd: postgresql-setup --initdb
when: postgresqldata.stat.exists == false
tags:
- install_db
- name: Database - Enable and start service postgresl
ansible.builtin.service:
@@ -82,10 +77,19 @@
service:
name: postgresql
state: restarted
enabled: true
tags:
- install_db
- name: Populate zabbix database
ansible.builtin.shell: 'zcat /usr/share/zabbix/sql-scripts/postgresql/server.sql.gz | psql -Uzabbix zabbix'
tags:
- install_db
- install_db
- name: Proxy - Enable and start service zabbix component
ansible.builtin.service:
name: "{{ item }}"
state: restarted
enabled: true
loop:
- zabbix-agent2