-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmonitor_instance.yaml
53 lines (43 loc) · 1.21 KB
/
monitor_instance.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
- hosts: tag_Name_Monitor
tasks: []
- name: Configure Monitoring
hosts:
- tag_Name_Monitor
sudo: true
roles:
- role: postgresql
postgresql_version: 93
postgresql_encoding: 'UTF-8'
postgresql_locale: 'en_US.UTF-8'
postgresql_directory: "/var/lib/pgsql93"
postgresql_unix_socket_directories:
- /var/run/postgresql
postgresql_admin_user: "postgres"
postgresql_default_auth_method: "trust"
remove_cluster: false
postgresql_users:
- name: zabbix_user
pass: Za661x
encrypted: no
postgresql_databases:
- name: zabbix_db
postgresql_user_privileges:
- name: zabbix_user
db: zabbix_db
priv: "ALL"
- name: Install Zabbix
hosts: tag_Name_Monitor
sudo: true
roles:
- role: zabbix-server
- name: Install Zabbix-agents
hosts:
- tag_Name_Redis
- tag_Name_Proxy
- tag_Name_BlogApp
- tag_Name_AdminApp
sudo: true
roles:
- role: zabbix-agent
zabbix_agent_Server: "{{ hostvars[groups['tag_Name_Monitor'][0]]['ec2_private_ip_address'] }}"
zabbix_agent_ServerActive: "{{ hostvars[groups['tag_Name_Monitor'][0]]['ec2_private_ip_address'] }}"