security

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2023 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type TenantManager

type TenantManager interface {
	// GetTenants returns all tenants.
	GetTenants() []string
	// GetUser returns user by tenant and username.
	GetUser(tenant string, username string) (*config.User, bool)
	// GetUsers returns users by tenant
	GetUsers(tenant string) ([]*config.User, bool)
	// GetClusters returns cluster names.
	GetClusters(tenant string) []string
	// GetTenantsOfCluster returns all tenants of cluster.
	GetTenantsOfCluster(cluster string) []string
	// PutUser puts a user into tenant.
	PutUser(tenant string, user *config.User)
	// RemoveUser removes a user from tenant.
	RemoveUser(tenant string, username string)
	// PutCluster puts a cluster into tenant.
	PutCluster(tenant string, cluster string)
	// RemoveCluster removes a cluster from tenant.
	RemoveCluster(tenant string, cluster string)
	// SetSupervisor gets supervisor info
	SetSupervisor(supervisor *config.User)
	// GetSupervisor gets supervisor info
	GetSupervisor() *config.User
}

TenantManager represents the manager of tenants.

func DefaultTenantManager

func DefaultTenantManager() TenantManager

Jump to

Keyboard shortcuts

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