summaryrefslogtreecommitdiffhomepage
path: root/applications/luci-app-lxc/luasrc/controller
diff options
context:
space:
mode:
authorJo-Philipp Wich <jo@mein.io>2020-04-19 17:14:58 +0200
committerJo-Philipp Wich <jo@mein.io>2020-04-19 17:17:26 +0200
commit74da73b012a7ac271d683f11d98de170215ae661 (patch)
treeeb0f31ad31b09b33b8166fdcaec9c57b86f01a47 /applications/luci-app-lxc/luasrc/controller
parent760763a7b5da42860c6c2d63478859bb02fa9104 (diff)
applications: add ACL dependency annotations to legacy controllers
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'applications/luci-app-lxc/luasrc/controller')
-rw-r--r--applications/luci-app-lxc/luasrc/controller/lxc.lua25
1 files changed, 20 insertions, 5 deletions
diff --git a/applications/luci-app-lxc/luasrc/controller/lxc.lua b/applications/luci-app-lxc/luasrc/controller/lxc.lua
index 9432110104..6fa1add0f8 100644
--- a/applications/luci-app-lxc/luasrc/controller/lxc.lua
+++ b/applications/luci-app-lxc/luasrc/controller/lxc.lua
@@ -30,12 +30,27 @@ function index()
page.target = cbi("lxc")
page.title = _("LXC Containers")
page.order = 70
+ page.acl_depends = { "luci-app-lxc" }
- entry({"admin", "services", "lxc_create"}, call("lxc_create"), nil).leaf = true
- entry({"admin", "services", "lxc_action"}, call("lxc_action"), nil).leaf = true
- entry({"admin", "services", "lxc_get_downloadable"}, call("lxc_get_downloadable"), nil).leaf = true
- entry({"admin", "services", "lxc_configuration_get"}, call("lxc_configuration_get"), nil).leaf = true
- entry({"admin", "services", "lxc_configuration_set"}, call("lxc_configuration_set"), nil).leaf = true
+ page = entry({"admin", "services", "lxc_create"}, call("lxc_create"), nil)
+ page.acl_depends = { "luci-app-lxc" }
+ page.leaf = true
+
+ page = entry({"admin", "services", "lxc_action"}, call("lxc_action"), nil)
+ page.acl_depends = { "luci-app-lxc" }
+ page.leaf = true
+
+ page = entry({"admin", "services", "lxc_get_downloadable"}, call("lxc_get_downloadable"), nil)
+ page.acl_depends = { "luci-app-lxc" }
+ page.leaf = true
+
+ page = entry({"admin", "services", "lxc_configuration_get"}, call("lxc_configuration_get"), nil)
+ page.acl_depends = { "luci-app-lxc" }
+ page.leaf = true
+
+ page = entry({"admin", "services", "lxc_configuration_set"}, call("lxc_configuration_set"), nil)
+ page.acl_depends = { "luci-app-lxc" }
+ page.leaf = true
end
function lxc_get_downloadable()