Newer
Older
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
#!/usr/bin/env ansible-playbook
---
- name: POSTGRES HA
hosts: postgres
tags: postgres
pre_tasks:
- name: check that repmgr_node_id is set
assert:
that: repmgr_node_id != ""
quiet: true
- name: check that repmgr_primary_node is set
assert:
that: repmgr_primary_node != ""
quiet: true
- name: install psycopg2
apt:
force_apt_get: true
install_recommends: false
name: python3-psycopg2
roles:
- postgres-ha
- name: POSTGRES HA CLIENTS
hosts:
- mediaserver
- mirismanager
tags: postgres
pre_tasks:
- name: check that haproxy is configured
assert:
that: hap_config_listen != ""
quiet: true
roles:
- haproxy
...