Documentation ¶
Index ¶
- Constants
- Variables
- func DeclareRBACRoles(service ac.Service, cfg *setting.Cfg, features featuremgmt.FeatureToggles) error
- func GetDataSourceRouteEvaluator(dsUID, action string) ac.Evaluator
- func GetPluginRouteEvaluator(pluginID, action string) ac.Evaluator
- func ReqCanAdminPlugins(cfg *setting.Cfg) func(rc *contextmodel.ReqContext) bool
Constants ¶
View Source
const ( // Plugins actions ActionInstall = "plugins:install" ActionWrite = "plugins:write" // App Plugins actions ActionAppAccess = "plugins.app:access" )
Variables ¶
View Source
var ( ScopeProvider = ac.NewScopeProvider("plugins") // Protects access to the Configuration > Plugins page AdminAccessEvaluator = ac.EvalAny(ac.EvalPermission(ActionWrite), ac.EvalPermission(ActionInstall)) )
Functions ¶
func DeclareRBACRoles ¶
func DeclareRBACRoles(service ac.Service, cfg *setting.Cfg, features featuremgmt.FeatureToggles) error
func GetDataSourceRouteEvaluator ¶
GetDataSourceRouteEvaluator returns an evaluator for the given data source UID and action.
func GetPluginRouteEvaluator ¶
GetPluginRouteEvaluator returns an evaluator for the given plugin ID and action.
func ReqCanAdminPlugins ¶
func ReqCanAdminPlugins(cfg *setting.Cfg) func(rc *contextmodel.ReqContext) bool
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.