Documentation
¶
Index ¶
- func GetUser(ctx context.Context) *userapi.User
- func Logout(ctx context.Context)
- func SetUser(ctx context.Context, user *userapi.User)
- type NamespaceMapper
- type NamespacePerUser
- type SingleNamespaceMapper
- type UserComponent
- func (c *UserComponent) AddToScope(ctx context.Context, scope *scopes.Scope)
- func (c *UserComponent) LoadUser(ctx context.Context, userID string) (*userapi.User, error)
- func (c *UserComponent) MapToUser(ctx context.Context, token *oauth2.Token, info *components.AuthenticationInfo) (*userapi.User, error)
- func (c *UserComponent) ProcessRequest(ctx context.Context, req *components.Request, ...) (components.Response, error)
- func (c *UserComponent) RegisterHandlers(s *components.Server, mux *http.ServeMux) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type NamespaceMapper ¶
type NamespacePerUser ¶
type NamespacePerUser struct {
// contains filtered or unexported fields
}
func (*NamespacePerUser) NamespaceForUserID ¶
func (m *NamespacePerUser) NamespaceForUserID(userID string) string
type SingleNamespaceMapper ¶
type SingleNamespaceMapper struct {
// contains filtered or unexported fields
}
func NewSingleNamespaceMapper ¶
func NewSingleNamespaceMapper(ns string) *SingleNamespaceMapper
func (*SingleNamespaceMapper) NamespaceForUserID ¶
func (m *SingleNamespaceMapper) NamespaceForUserID(userID string) string
type UserComponent ¶
type UserComponent struct {
// contains filtered or unexported fields
}
func NewUserComponent ¶
func NewUserComponent(kube *kubeclient.Client, namespaceMapper NamespaceMapper) (*UserComponent, error)
func (*UserComponent) AddToScope ¶
func (c *UserComponent) AddToScope(ctx context.Context, scope *scopes.Scope)
func (*UserComponent) MapToUser ¶
func (c *UserComponent) MapToUser(ctx context.Context, token *oauth2.Token, info *components.AuthenticationInfo) (*userapi.User, error)
func (*UserComponent) ProcessRequest ¶
func (c *UserComponent) ProcessRequest(ctx context.Context, req *components.Request, next components.RequestFilterChain) (components.Response, error)
func (*UserComponent) RegisterHandlers ¶
func (c *UserComponent) RegisterHandlers(s *components.Server, mux *http.ServeMux) error
Click to show internal directories.
Click to hide internal directories.