Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BuildClientFunc ¶
BuildClientFunc defines a function that builds a controller-runtime client that impersonates the given user
func BuildBuildClientFuncForConfig ¶
func BuildBuildClientFuncForConfig(config *rest.Config) BuildClientFunc
BuildBuildClientFuncForConfig provides a configured BuildClientFunc for building a controller-runtime client for a given cluster and impersonating an user
type WriteClient ¶
type WriteClient struct {
// contains filtered or unexported fields
}
WriteClient implements Write primitives on Workspaces. Creates or updates InternalWorkspaces starting from a request on Workspaces.
func New ¶
func New(buildClient BuildClientFunc, workspacesNamespace string, workspacesReader *iwclient.Client) *WriteClient
New creates a new WriteClient
func NewWithConfig ¶
func NewWithConfig(config *rest.Config, workspacesNamespace string, workspacesReader *iwclient.Client) *WriteClient
NewWithConfig creates a new WriteClient initialized with the given configuration
func (*WriteClient) CreateUserWorkspace ¶
func (c *WriteClient) CreateUserWorkspace(ctx context.Context, user string, workspace *restworkspacesv1alpha1.Workspace, opts ...client.CreateOption) error
CreateUserWorkspace creates as `user` the InternalWorkspace representing the provided Workspace
func (*WriteClient) UpdateUserWorkspace ¶
func (c *WriteClient) UpdateUserWorkspace(ctx context.Context, user string, workspace *restworkspacesv1alpha1.Workspace, opts ...client.UpdateOption) error
UpdateUserWorkspace updates as `user` the InternalWorkspace representing the provided Workspace