evoacme: support for haproxy
This commit is contained in:
parent
78a2fd9830
commit
338c083c5b
|
@ -56,4 +56,13 @@ if [ $? == 0 ]; then
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
which haproxy>/dev/null
|
||||||
|
if [ $? == 0 ]; then
|
||||||
|
mkdir -p /etc/ssl/haproxy -m 700
|
||||||
|
cat $CRT_DIR/${vhost}-fullchain.pem $SSL_KEY_DIR/${vhost}.key > /etc/ssl/haproxy/${vhost}.pem
|
||||||
|
haproxy -c -f /etc/haproxy/haproxy.cfg 1>/dev/null
|
||||||
|
if [ $? == 0 ]; then
|
||||||
|
service haproxy reload
|
||||||
|
fi
|
||||||
|
fi
|
||||||
exit 0
|
exit 0
|
||||||
|
|
15
evoacme/templates/nginx-haproxy.conf.j2
Normal file
15
evoacme/templates/nginx-haproxy.conf.j2
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
server {
|
||||||
|
listen unix:/run/nginx-letsencrypt.sock;
|
||||||
|
|
||||||
|
root {{ evoacme_acme_dir }};
|
||||||
|
|
||||||
|
access_log /var/log/nginx/access.log;
|
||||||
|
error_log /var/log/nginx/error.log;
|
||||||
|
|
||||||
|
server_name _;
|
||||||
|
|
||||||
|
location / {
|
||||||
|
try_files $uri =404;
|
||||||
|
allow all;
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in a new issue