diff options
author | Jo-Philipp Wich <jo@mein.io> | 2022-11-22 10:27:15 +0100 |
---|---|---|
committer | Jo-Philipp Wich <jo@mein.io> | 2022-11-22 10:56:36 +0100 |
commit | 6e6fce3eb43ea6899eedc91bebd5713a5d4c773b (patch) | |
tree | 281b09a0e3977ec940896416341f1bb8b3008399 /protocols/luci-proto-wireguard/root/usr/share | |
parent | 90a2b1eaeb58b7169b31fdc097c5bfe6f557c778 (diff) |
luci-proto-wireguard: merge status page functionality
Merge status page functionality from the separate `luci-app-wireguard`
package into the `luci-proto-wirguard` protocol backend.
Also rewrite the status page markup to be more compact while we're at it.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'protocols/luci-proto-wireguard/root/usr/share')
-rw-r--r-- | protocols/luci-proto-wireguard/root/usr/share/luci/menu.d/luci-proto-wireguard.json | 14 | ||||
-rw-r--r-- | protocols/luci-proto-wireguard/root/usr/share/rpcd/acl.d/luci-wireguard.json | 5 |
2 files changed, 19 insertions, 0 deletions
diff --git a/protocols/luci-proto-wireguard/root/usr/share/luci/menu.d/luci-proto-wireguard.json b/protocols/luci-proto-wireguard/root/usr/share/luci/menu.d/luci-proto-wireguard.json new file mode 100644 index 0000000000..06940ee7ef --- /dev/null +++ b/protocols/luci-proto-wireguard/root/usr/share/luci/menu.d/luci-proto-wireguard.json @@ -0,0 +1,14 @@ +{ + "admin/status/wireguard": { + "title": "WireGuard", + "order": 92, + "action": { + "type": "view", + "path": "wireguard/status" + }, + "depends": { + "acl": [ "luci-proto-wireguard" ], + "uci": { "network": true } + } + } +} diff --git a/protocols/luci-proto-wireguard/root/usr/share/rpcd/acl.d/luci-wireguard.json b/protocols/luci-proto-wireguard/root/usr/share/rpcd/acl.d/luci-wireguard.json index 674deb6c7d..e7187c0e4f 100644 --- a/protocols/luci-proto-wireguard/root/usr/share/rpcd/acl.d/luci-wireguard.json +++ b/protocols/luci-proto-wireguard/root/usr/share/rpcd/acl.d/luci-wireguard.json @@ -5,6 +5,11 @@ "file": { "/usr/bin/qrencode --inline --8bit --type=SVG --output=- -- *": [ "exec" ] }, + "ubus": { + "luci.wireguard": [ + "getWgInstances" + ] + }, "uci": [ "ddns", "system" ] }, "write": { |