diff --git a/net/haproxy/pkg-descr b/net/haproxy/pkg-descr index c4e4ba901..0b23647bf 100644 --- a/net/haproxy/pkg-descr +++ b/net/haproxy/pkg-descr @@ -11,6 +11,12 @@ Plugin Changelog Added: * add support for advanced resolver properties (#2330) +Fixed: +* no haproxy.conf after restoring a config backup (#2474) + +Changed: +* deploy haproxy.conf if it does not exist (#2474) + 3.5 Fixed: diff --git a/net/haproxy/src/etc/rc.syshook.d/start/50-haproxy b/net/haproxy/src/etc/rc.syshook.d/start/50-haproxy new file mode 100755 index 000000000..09c0e0ef1 --- /dev/null +++ b/net/haproxy/src/etc/rc.syshook.d/start/50-haproxy @@ -0,0 +1,7 @@ +#!/bin/sh + +# fallback if no config file exists (i.e. after config backup restore) +if [ ! -e /usr/local/etc/haproxy.conf -a -e /usr/local/etc/haproxy.conf.staging ]; then + cp /usr/local/etc/haproxy.conf.staging /usr/local/etc/haproxy.conf + /usr/local/etc/rc.d/haproxy start +fi