Instead of waiting for interface to be up,
wait for it to have IPs, as this is what we need.
Also do not call procd_open_instance when not ready.
Signed-off-by: Etienne Champetier <champetier.etienne@gmail.com>
(cherry picked from commit 1dd46bca62)
listen_ipv6 config option is removed and we now
listen on both ipv4 and ipv6 addresses.
HTTP keepalive is enabled and set to 70s by default.
With uhttpd-mod-lua there is a small change in behavior,
all code is loaded/parsed/executed once on startup as before,
but now each request is executed in his own fork, so we can't
keep a state between requests.
Signed-off-by: Etienne Champetier <champetier.etienne@gmail.com>
(cherry picked from commit 60460f0046)
This happens during compilation:
Enabling network
./etc/init.d/prometheus-node-exporter-lua: line 7: /lib/functions/network.sh: No such file or directory
Signed-off-by: Rosen Penev <rosenp@gmail.com>
Drop the config knob 'listen_address' and introduce 'listen_interface'
and 'listen_ipv6' instead.
'listen_interface' takes an openwrt interface name ('loopback', 'lan',
'wan' etc, or "*" for all), from which the primary IP is used to listen
on. If 'listen_ipv6' is set to '1', the IPv6 adress will be used, IPv4
elsewise.
procd interface triggers are now combined with this, so if the listen
interface is not yet configured when the init script is executed, the
process start is defered, and the trigger takes care of that once
the interface is ready.
Fixes#7670
Signed-off-by: Andre Heider <a.heider@gmail.com>