From a5852761c39b2a00337984ad49bfdb7beeb15f75 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Wed, 29 Jul 2020 14:11:39 +0200 Subject: [PATCH 19/30] uhttp: adds the deployed option This allows us to make sure the webui is not automatically started if the unit is already deployed. Signed-off-by: John Crispin --- package/network/services/uhttpd/files/uhttpd.init | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/package/network/services/uhttpd/files/uhttpd.init b/package/network/services/uhttpd/files/uhttpd.init index 6322473b97..5e57bd66da 100755 --- a/package/network/services/uhttpd/files/uhttpd.init +++ b/package/network/services/uhttpd/files/uhttpd.init @@ -207,3 +207,10 @@ start_service() { config_load uhttpd config_foreach start_instance uhttpd } + +boot() { + local deployed=$(uci get uhttpd.main.deployed) + + [ "$deployed" -eq 1 ] && return 0 + start $@ +} -- 2.25.1