Documentation ¶
Index ¶
- func NewLocalDoguFetcher(doguVersionRegistry doguVersionRegistry, ...) *localDoguFetcher
- func NewResourceDoguFetcher(client client.Client, doguRemoteRepository remoteDoguDescriptorRepository) *resourceDoguFetcher
- type CesDoguRegistrator
- type DoguRegistrator
- type K8sClient
- type LocalDoguFetcher
- type ResourceDoguFetcher
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewLocalDoguFetcher ¶
func NewLocalDoguFetcher(doguVersionRegistry doguVersionRegistry, doguDescriptorRepo localDoguDescriptorRepository) *localDoguFetcher
NewLocalDoguFetcher creates a new dogu fetcher that provides descriptors for dogus.
func NewResourceDoguFetcher ¶
func NewResourceDoguFetcher(client client.Client, doguRemoteRepository remoteDoguDescriptorRepository) *resourceDoguFetcher
NewResourceDoguFetcher creates a new dogu fetcher that provides descriptors for dogus.
Types ¶
type CesDoguRegistrator ¶
type CesDoguRegistrator struct {
// contains filtered or unexported fields
}
CesDoguRegistrator is responsible for register dogus in the cluster
func NewCESDoguRegistrator ¶
func NewCESDoguRegistrator(doguVersionRegistry doguVersionRegistry, doguDescriptorRepo localDoguDescriptorRepository) *CesDoguRegistrator
NewCESDoguRegistrator creates a new instance of the dogu registrator. It registers dogus in the dogu registry and generates keypairs
func (*CesDoguRegistrator) RegisterDoguVersion ¶
RegisterDoguVersion registers an upgrade of an existing dogu in a cluster. Use RegisterNewDogu() to complete new dogu installations.
func (*CesDoguRegistrator) RegisterNewDogu ¶
func (c *CesDoguRegistrator) RegisterNewDogu(ctx context.Context, _ *k8sv2.Dogu, dogu *core.Dogu) error
RegisterNewDogu registers a completely new dogu in a cluster. Use RegisterDoguVersion() for upgrades of an existing dogu.
func (*CesDoguRegistrator) UnregisterDogu ¶
func (c *CesDoguRegistrator) UnregisterDogu(ctx context.Context, doguName string) error
UnregisterDogu deletes a dogu from the dogu registry
type DoguRegistrator ¶
type DoguRegistrator interface { // RegisterNewDogu registers a new dogu in the local dogu registry. RegisterNewDogu(ctx context.Context, doguResource *k8sv2.Dogu, dogu *cesappcore.Dogu) error // RegisterDoguVersion registers a new version for an existing dogu in the dogu registry. RegisterDoguVersion(ctx context.Context, dogu *cesappcore.Dogu) error // UnregisterDogu removes a registration of a dogu from the local dogu registry. UnregisterDogu(ctx context.Context, dogu string) error }
DoguRegistrator includes functionality to manage the registration of dogus in the local dogu registry.
type LocalDoguFetcher ¶
type LocalDoguFetcher interface { // FetchInstalled fetches the dogu from the local registry and returns it with patched dogu dependencies (which // otherwise might be incompatible with K8s CES). FetchInstalled(ctx context.Context, doguName string) (installedDogu *cesappcore.Dogu, err error) // Enabled checks is the given dogu is enabled. // Returns false (without error), when the dogu is not installed Enabled(ctx context.Context, doguName string) (bool, error) }
LocalDoguFetcher includes functionality to search the local dogu registry for a dogu.
type ResourceDoguFetcher ¶
type ResourceDoguFetcher interface { // FetchWithResource fetches the dogu either from the remote dogu registry or from a local development dogu map and // returns it with patched dogu dependencies (which otherwise might be incompatible with K8s CES). FetchWithResource(ctx context.Context, doguResource *k8sv2.Dogu) (*cesappcore.Dogu, *k8sv2.DevelopmentDoguMap, error) }
ResourceDoguFetcher includes functionality to get a dogu either from the remote dogu registry or from a local development dogu map.