summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-app-sqm/root/usr
diff options
context:
space:
mode:
authorAnsuel Smith <ansuelsmth@gmail.com>2020-10-19 14:54:18 +0200
committerToke Høiland-Jørgensen <toke@toke.dk>2020-10-23 23:05:14 +0200
commit63aea8f84831a01c49ee8731196f1c4d1d81ddfd (patch)
treee5f0c47b6eeaed67f1666d44fbe140e973bbe315 /applications/luci-app-sqm/root/usr
parent71a8de9200e29d1ce5b5590c63a721e2419a41b1 (diff)
luci-app-sqm: convert to client side implementation
Convert sqm app to client side implementation. Only a small rework in the logic to get qos scripts help text. The rest of the script is a porting 1:1. Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
Diffstat (limited to 'applications/luci-app-sqm/root/usr')
-rw-r--r--applications/luci-app-sqm/root/usr/share/luci/menu.d/luci-app-sqm.json13
-rw-r--r--applications/luci-app-sqm/root/usr/share/rpcd/acl.d/luci-app-sqm.json10
2 files changed, 22 insertions, 1 deletions
diff --git a/applications/luci-app-sqm/root/usr/share/luci/menu.d/luci-app-sqm.json b/applications/luci-app-sqm/root/usr/share/luci/menu.d/luci-app-sqm.json
new file mode 100644
index 0000000000..6c5ff4fa62
--- /dev/null
+++ b/applications/luci-app-sqm/root/usr/share/luci/menu.d/luci-app-sqm.json
@@ -0,0 +1,13 @@
+{
+ "admin/network/sqm": {
+ "title": "SQM QoS",
+ "order": 59,
+ "action": {
+ "type": "view",
+ "path": "network/sqm"
+ },
+ "depends": {
+ "acl": [ "luci-app-sqm" ]
+ }
+ }
+}
diff --git a/applications/luci-app-sqm/root/usr/share/rpcd/acl.d/luci-app-sqm.json b/applications/luci-app-sqm/root/usr/share/rpcd/acl.d/luci-app-sqm.json
index 583a54ae5a..2b56b1fc78 100644
--- a/applications/luci-app-sqm/root/usr/share/rpcd/acl.d/luci-app-sqm.json
+++ b/applications/luci-app-sqm/root/usr/share/rpcd/acl.d/luci-app-sqm.json
@@ -2,7 +2,15 @@
"luci-app-sqm": {
"description": "Grant UCI access for luci-app-sqm",
"read": {
- "uci": [ "sqm" ]
+ "file": {
+ "/var/run/sqm/available_qdiscs": [ "list" ],
+ "/usr/lib/sqm/*.qos.help": [ "read" ]
+ },
+ "uci": [ "sqm" ],
+ "ubus": {
+ "file": [ "read", "list" ],
+ "luci": [ "setInitAction" ]
+ }
},
"write": {
"uci": [ "sqm" ]