importer

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: May 28, 2025 License: AGPL-3.0 Imports: 7 Imported by: 0

Documentation

Overview

Package importer provides business access to the importer's kubernetes API.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDoguClient

func NewDoguClient(doguCli DoguInterface) *doguClient

NewDoguClient creates a new client that operates on dogu deployments on the importer system.

Types

type DoguInterface

type DoguInterface interface {
	// List takes label and field selectors and returns the list of Dogus that match those selectors.
	List(ctx context.Context, opts metav1.ListOptions) (result *doguV2.DoguList, err error)
	// Get returns a single dogu CR if it exists in the k8s cluster.
	Get(ctx context.Context, name string, opts metav1.GetOptions) (*doguV2.Dogu, error)
	// UpdateSpecWithRetry tries to update the provided dogu with the given update function and returns the updated
	// copy. If a conflict happens, the update will be retried with the same function.
	UpdateSpecWithRetry(ctx context.Context, dogu *doguV2.Dogu, updateFunc func(spec doguV2.DoguSpec) doguV2.DoguSpec, opts metav1.UpdateOptions) (*doguV2.Dogu, error)
}

Jump to

Keyboard shortcuts

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