util

package
v0.1.18 Latest Latest
Warning

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

Go to latest
Published: Aug 10, 2020 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ChangeAttributesResource added in v0.1.2

func ChangeAttributesResource(a authorizer.Attributes, groupVersionResource schema.GroupVersionResource, namespace string) authorizer.Attributes

func CreateRoleBinding

func CreateRoleBinding(ctx context.Context, client client.Client, namespace string, owner *configv1alpha1.Account, scheme *runtime.Scheme) error

CreateRoleBinding creates a new role binding for the target account with the given name and namespace

func ForbiddenMessage added in v0.1.10

func ForbiddenMessage(attributes authorizer.Attributes) string

func GetAccountsByUserInfo added in v0.1.2

func GetAccountsByUserInfo(ctx context.Context, client client2.Client, userInfo user.Info) ([]*configv1alpha1.Account, error)

func GetClusterRoleFor

func GetClusterRoleFor(account *configv1alpha1.Account) string

GetClusterRoleFor returns the cluster role for the given account if there is any

func IsUserPartOfAccount added in v0.1.2

func IsUserPartOfAccount(userInfo user.Info, account *configv1alpha1.Account) bool

Types

This section is empty.

Jump to

Keyboard shortcuts

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