applications/luci-asterisk: register with ucitrack
authorJo-Philipp Wich <jow@openwrt.org>
Sun, 11 Jan 2009 04:20:34 +0000 (04:20 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Sun, 11 Jan 2009 04:20:34 +0000 (04:20 +0000)
applications/luci-asterisk/ipkg/postinst [new file with mode: 0755]
applications/luci-asterisk/root/etc/uci-defaults/luci-asterisk [new file with mode: 0644]

diff --git a/applications/luci-asterisk/ipkg/postinst b/applications/luci-asterisk/ipkg/postinst
new file mode 100755 (executable)
index 0000000..68f2b1a
--- /dev/null
@@ -0,0 +1,4 @@
+#!/bin/sh
+[ -n "${IPKG_INSTROOT}" ] || {
+       ( . /etc/uci-defaults/luci-asterisk ) && rm -f /etc/uci-defaults/luci-asterisk
+}
diff --git a/applications/luci-asterisk/root/etc/uci-defaults/luci-asterisk b/applications/luci-asterisk/root/etc/uci-defaults/luci-asterisk
new file mode 100644 (file)
index 0000000..4e24650
--- /dev/null
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+uci batch <<-EOF
+       add ucitrack asterisk
+       set ucitrack.@olsrd[-1].init=asterisk
+       commit ucitrack
+EOF