From 054ae9686f79ebe459c561cca0de73eb885d916a Mon Sep 17 00:00:00 2001 From: Anjan Chanda Date: Tue, 9 Oct 2018 15:40:27 +0200 Subject: [PATCH] netmode: add 'netmode' in owsd ubusproxy --- .../etc/uci-defaults/997-owsd-with-ubusx-netmode | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 netmode/files/etc/uci-defaults/997-owsd-with-ubusx-netmode diff --git a/netmode/files/etc/uci-defaults/997-owsd-with-ubusx-netmode b/netmode/files/etc/uci-defaults/997-owsd-with-ubusx-netmode new file mode 100644 index 000000000..e1cbfcba4 --- /dev/null +++ b/netmode/files/etc/uci-defaults/997-owsd-with-ubusx-netmode @@ -0,0 +1,13 @@ +#!/bin/sh + +. /lib/functions.sh + +add_owsd_ubusproxy_object_netmode() { + local netmd=$(uci -q get owsd.ubusproxy.object | grep netmode) + if [ -z "$netmd" ]; then + uci -q add_list owsd.ubusproxy.object="netmode" + uci commit owsd + fi +} + +add_owsd_ubusproxy_object_netmode