From 5530642b006bdd35efac753b09bab95f89eee620 Mon Sep 17 00:00:00 2001 From: Eugene Date: Mon, 8 Oct 2018 11:03:46 -0700 Subject: [PATCH] haproxy config through env --- entrypoint.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/entrypoint.sh b/entrypoint.sh index 0a29335..ef869c8 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -9,4 +9,8 @@ done cp -rf /opt/haproxy/error-pages /etc/haproxy/ -exec haproxy -f /etc/haproxy/haproxy.cfg -W -db +if [ -z "$CONFIG" ]; then + CONFIG="/etc/haproxy/haproxy.cfg" +fi + +exec haproxy -f $CONFIG -W -db