rbac

package
v1.19.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 25, 2022 License: MIT Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var WorkerId string

Functions

func SyncRbacFromAuth

func SyncRbacFromAuth()

sync rbac data from paas_auth subserver

func SyncRbacFromConf

func SyncRbacFromConf(rbacDatas []options.RbacData)

init rbac data from init conf

Types

type AuthRbacData

type AuthRbacData struct {
	Operation        string     `json:"operation"`
	Principal        Principals `json:"principal"`
	ScopeType        string     `json:"scope_type"`
	ScopeInstance    string     `json:"scope_instance"`
	Service          string     `json:"service"`
	Action           string     `json:"action"`
	ResourceType     string     `json:"resource_type"`
	ResourceInstance Resource   `json:"resource_instance"`
	PolicyFrom       string     `json:"policy_from"`
}

type Principals

type Principals struct {
	PrincipalType string `json:"principal_type"`
	PrincipalId   string `json:"principal_id"`
}

type Resource

type Resource struct {
	Cluster   string `json:"cluster"`
	Namespace string `json:"namespace"`
}

type WebsocketReq

type WebsocketReq struct {
	AppCode  string `json:"app_code"`
	Type     string `json:"type"`
	WorkerId string `json:"worker_id"`
	DataId   string `json:"data_id"`
}

type WebsocketRespnse

type WebsocketRespnse struct {
	AppCode  string `json:"app_code"`
	Type     string `json:"type"`
	WorkerId string `json:"worker_id"`
	DataId   string `json:"data_id"`
	Data     string `json:"data"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL