mirror of
https://gitlab.sectorq.eu/jaydee/ansible.git
synced 2026-03-13 05:42:46 +01:00
build
This commit is contained in:
@@ -1,3 +1,4 @@
|
|||||||
zabbix_api_url: "https://zabbix.sectorq.eu/api_jsonrpc.php"
|
zabbix_api_url: "https://zabbix.sectorq.eu/api_jsonrpc.php"
|
||||||
dnf_proxy_host: "192.168.77.101"
|
dnf_proxy_host: "192.168.77.101"
|
||||||
dnf_proxy_port: "3128"
|
dnf_proxy_port: "3128"
|
||||||
|
zabbix_user: jd
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
- name: Install Zabbix Proxy on Debian 13
|
- name: Install Zabbix Proxy on AlmaLinux 10
|
||||||
vars:
|
vars:
|
||||||
zabbix_version: "7.4"
|
zabbix_version: "7.4"
|
||||||
zabbix_server_ip: "192.168.77.101"
|
zabbix_server_ip: "192.168.77.101"
|
||||||
@@ -20,6 +20,14 @@
|
|||||||
set_fact:
|
set_fact:
|
||||||
clustename: "alma10"
|
clustename: "alma10"
|
||||||
|
|
||||||
|
- name: Allow user to start/stop zabbix-proxy with sudo without password
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: "/etc/sudoers.d/{{ zabbix_user }}-zabbix-proxy"
|
||||||
|
content: "{{ zabbix_user }} ALL=(ALL) NOPASSWD: /bin/systemctl start zabbix-proxy, /bin/systemctl stop zabbix-proxy"
|
||||||
|
owner: root
|
||||||
|
group: root
|
||||||
|
mode: '0440'
|
||||||
|
|
||||||
- name: Configure global DNF proxy
|
- name: Configure global DNF proxy
|
||||||
ansible.builtin.lineinfile:
|
ansible.builtin.lineinfile:
|
||||||
path: /etc/dnf/dnf.conf
|
path: /etc/dnf/dnf.conf
|
||||||
|
|||||||
@@ -17,6 +17,15 @@
|
|||||||
- name: Set proxy name
|
- name: Set proxy name
|
||||||
set_fact:
|
set_fact:
|
||||||
clustename: "debian13"
|
clustename: "debian13"
|
||||||
|
- name: Allow user to start/stop zabbix-proxy with sudo without password
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: "/etc/sudoers.d/{{ zabbix_user }}-zabbix-proxy"
|
||||||
|
content: "{{ zabbix_user }} ALL=(ALL) NOPASSWD: /bin/systemctl start zabbix-proxy, /bin/systemctl stop zabbix-proxy"
|
||||||
|
owner: root
|
||||||
|
group: root
|
||||||
|
mode: '0440'
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
- name: Show default IP
|
- name: Show default IP
|
||||||
ansible.builtin.debug:
|
ansible.builtin.debug:
|
||||||
|
|||||||
@@ -20,6 +20,15 @@
|
|||||||
set_fact:
|
set_fact:
|
||||||
clustename: "rocky9"
|
clustename: "rocky9"
|
||||||
|
|
||||||
|
- name: Allow user to start/stop zabbix-proxy with sudo without password
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: "/etc/sudoers.d/{{ zabbix_user }}-zabbix-proxy"
|
||||||
|
content: "{{ zabbix_user }} ALL=(ALL) NOPASSWD: /bin/systemctl start zabbix-proxy, /bin/systemctl stop zabbix-proxy"
|
||||||
|
owner: root
|
||||||
|
group: root
|
||||||
|
mode: '0440'
|
||||||
|
|
||||||
|
|
||||||
- name: Configure global DNF proxy
|
- name: Configure global DNF proxy
|
||||||
ansible.builtin.lineinfile:
|
ansible.builtin.lineinfile:
|
||||||
path: /etc/dnf/dnf.conf
|
path: /etc/dnf/dnf.conf
|
||||||
|
|||||||
Reference in New Issue
Block a user