-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathmain.yml
More file actions
39 lines (39 loc) · 943 Bytes
/
main.yml
File metadata and controls
39 lines (39 loc) · 943 Bytes
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
---
- name: Disable haproxy-related services
service:
name: "{{ item }}"
state: stopped
enabled: no
failed_when: no
loop:
- named-scripts-proxy
- haproxy
- name: Remove haproxy-related configuration
file:
path: "{{ item }}"
state: absent
loop:
- /etc/named.scripts-proxy.conf
- /etc/systemd/system/named-scripts-proxy.service
- /etc/haproxy/haproxy.cfg
- /etc/rsyslog.d/haproxy.conf
- /etc/systemd/system/haproxy.service.d/10-scripts.conf
- /usr/local/bin/hatop
- name: Remove haproxy-related packages
dnf:
name:
- bind
- bind-dlz-ldap
- haproxy
state: absent
- name: Install scripts-proxy
dnf:
name:
- scripts-proxy
state: present
- name: Configure scripts-proxy
copy:
dest: /etc/sysconfig/scripts-proxy
content: |
OPTIONS="-ldap_servers={{ groups['scripts-ldap'] | join(':389,') }}:389"
notify: restart scripts-proxy