Skip to content
This repository has been archived by the owner on Jun 18, 2024. It is now read-only.

Commit

Permalink
update haproxy configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
Julien Francoz committed Jan 29, 2020
1 parent 0bee7dc commit 8b5a958
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ ENV CONFIG_DIR=/usr/local/etc/haproxy/
# lua http
RUN curl https://raw.githubusercontent.com/haproxytech/haproxy-lua-http/master/http.lua > /http.lua
# https://github.com/haproxytech/haproxy-lua-acme
RUN curl https://raw.githubusercontent.com/haproxytech/haproxy-lua-acme/master/acme.lua > /acme.lua \
&& curl https://raw.githubusercontent.com/haproxytech/haproxy-lua-acme/master/config.lua > /config.lua \
&& curl https://raw.githubusercontent.com/haproxytech/haproxy-lua-acme/master/haproxy.cfg > $CONFIG_DIR/haproxy.cfg
ADD acme.lua /acme.lua
ADD config.lua /config.lua
ADD haproxy.cfg $CONFIG_DIR/haproxy.cfg
# check conf
RUN haproxy -c -- $CONFIG_DIR/haproxy.cfg

7 changes: 3 additions & 4 deletions haproxy.cfg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
global
log /dev/log local0 debug
log stdout format raw local0 debug
daemon
lua-load config.lua
lua-load acme.lua
Expand All @@ -13,7 +13,7 @@ defaults
timeout server 10s

listen http
bind *:5002
bind *:80
http-request use-service lua.acme if { path_beg /.well-known/acme-challenge/ }

listen acme
Expand All @@ -22,6 +22,5 @@ listen acme

listen acme-ca
bind 127.0.0.1:9012
# server ca acme-v02.api.letsencrypt.org:443 ssl verify none
server ca 127.0.0.1:4431 ssl verify none
server ca acme-v02.api.letsencrypt.org:443 ssl verify none
http-request set-header Host acme-v02.api.letsencrypt.org

0 comments on commit 8b5a958

Please sign in to comment.