Hello, we are trying to set up a configuration were the server (not the backend) is dynamically selected by a LUA script.
We came up with this conf which is not working:
global lua-load choose-server.lua defaults mode http frontend http-in bind *:10001 # The LUA variable is working in case we use to select the backend: #use_backend %[lua.choose_backend] default_backend dynamic backend dynamic # Instead in this case it is not working server s1 %[lua.choose_server]
When starting the server we get this error:
[ALERT] 061/171533 (3343) : parsing [haproxy.conf:16] : 'server s1' : invalid address: '%[lua.choose_server]' in '%[lua.choose_server]'
Is this not supported? Is there any other way to achieve the same result?