luci-app-dockerman: move config_load into start function
authorFlorian Eckert <fe@dev.tdt.de>
Fri, 19 Jun 2020 12:08:40 +0000 (14:08 +0200)
committerFlorian Eckert <fe@dev.tdt.de>
Mon, 13 Jul 2020 10:54:27 +0000 (12:54 +0200)
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
applications/luci-app-dockerman/root/etc/init.d/dockerman

index 22629c193356aea1ca7f07bd3cd8606bd25851d0..601dcf9c7caeacd10254b0f086dd4a91ed7bcc65 100755 (executable)
@@ -3,9 +3,6 @@
 START=99
 DOCKERD_CONF="/etc/docker/daemon.json"
 
-config_load dockerman
-config_get daemon_ea "local" daemon_ea
-
 init_dockerman_chain(){
        iptables -N DOCKER-MAN >/dev/null 2>&1
        iptables -F DOCKER-MAN >/dev/null 2>&1
@@ -31,6 +28,10 @@ handle_allowed_interface(){
 
 start(){
        [ ! -x "/etc/init.d/dockerd" ] && return 0
+
+       config_load dockerman
+       config_get daemon_ea "local" daemon_ea
+
        init_dockerman_chain
        if [ -n "$daemon_ea" ]; then
                handle_allowed_interface