Drop acme.sh hot update requirements, use reload instead
This commit is contained in:
1 parent
8bfad85504
commit
738516a15b
2 files changed
+4
-18
No files matched your search
+3
-2
@@ -46,6 +46,7 @@ haproxy_acmesh: []
|
|||||||
# must_present: /etc/haproxy/certs/ykn.fr.pem
|
# must_present: /etc/haproxy/certs/ykn.fr.pem
|
||||||
# must_absent: /etc/haproxy/haproxy.cfg
|
# must_absent: /etc/haproxy/haproxy.cfg
|
||||||
# env:
|
# env:
|
||||||
# DEPLOY_HAPROXY_HOT_UPDATE: "yes"
|
# # Seamless reload (master-worker), saved by acme.sh for renewals
|
||||||
# DEPLOY_HAPROXY_STATS_SOCKET: /var/run/haproxy/admin.sock
|
# DEPLOY_HAPROXY_HOT_UPDATE: "no"
|
||||||
|
# DEPLOY_HAPROXY_RELOAD: systemctl reload haproxy.service
|
||||||
# DEPLOY_HAPROXY_PEM_PATH: "{{ haproxy_certs_path }}"
|
# DEPLOY_HAPROXY_PEM_PATH: "{{ haproxy_certs_path }}"
|
||||||
+1
-16
@@ -1,24 +1,9 @@
|
|||||||
---
|
---
|
||||||
# tasks file for haproxy
|
# tasks file for haproxy
|
||||||
|
|
||||||
# socat is required by the acme.sh haproxy deploy hook to hot update
|
|
||||||
# certificates through the stats socket (DEPLOY_HAPROXY_HOT_UPDATE)
|
|
||||||
- name: Install acme.sh
|
- name: Install acme.sh
|
||||||
ansible.builtin.apt:
|
ansible.builtin.apt:
|
||||||
name:
|
name: acme.sh
|
||||||
- acme.sh
|
|
||||||
- socat
|
|
||||||
become: true
|
|
||||||
|
|
||||||
# acme.sh 3.1.1 (Debian 13 package) sends "set ssl cert" with `echo -e`,
|
|
||||||
# which dash (/bin/sh) does not support: haproxy receives "-e set ssl cert"
|
|
||||||
# and the hot update fails. Apply the upstream fix (printf '%b\n').
|
|
||||||
# No-op once the packaged hook is fixed.
|
|
||||||
- name: Fix acme.sh haproxy deploy hook hot update under dash
|
|
||||||
ansible.builtin.replace:
|
|
||||||
path: /usr/share/acme.sh/deploy/haproxy.sh
|
|
||||||
regexp: 'echo -e ''(\$\{_cmdpfx\}set ssl cert )'
|
|
||||||
replace: 'printf ''%b\\n'' ''\1'
|
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
# Always run: also covers instances where acme.sh is already installed
|
# Always run: also covers instances where acme.sh is already installed
|
||||||
|
|||||||
Reference in new issue
Block a user