k8s

package
v1.16.0 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2023 License: Apache-2.0 Imports: 30 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CertsFolder = "/tmp/k8s-webhook-server/serving-certs"
	CertsTLSKey = "tls.key"
	CertsTLSCrt = "tls.crt"
	CertsTLSCa  = "ca.crt"

	ResourceFolder            = "/tmp/operator-resources"
	CRDFilenameV1             = "crd-v1.yaml"
	MutatingWebhookFilename   = "mutate.yaml"
	ValidatingWebhookFilename = "validate.yaml"
	ConfigMapFilename         = "configmap.yaml"
	ServiceFilename           = "service.yaml"

	ManagerDeploymentName = "seldon-controller-manager"
	CRDName               = "seldondeployments.machinelearning.seldon.io"
)
View Source
const DefaultMinorVersion = 18

This will cause CRD V1 to be installed

View Source
const MutatingWebhookName = "seldon-mutating-webhook-configuration"

Variables

This section is empty.

Functions

func GetServerVersion added in v1.11.1

func GetServerVersion(client discovery.DiscoveryInterface, logger logr.Logger) (string, error)

func InitializeOperator

func InitializeOperator(ctx context.Context, config *rest.Config, namespace string, logger logr.Logger, scheme *runtime.Scheme, watchNamespace bool) error

func LoadBytesFromFile

func LoadBytesFromFile(path string, name string) ([]byte, error)

Types

type Cert

type Cert struct {
	// contains filtered or unexported fields
}

type ConfigmapCreator

type ConfigmapCreator struct {
	// contains filtered or unexported fields
}

func NewConfigmapCreator

func NewConfigmapCreator(client kubernetes.Interface, logger logr.Logger, scheme *runtime.Scheme) *ConfigmapCreator

func (*ConfigmapCreator) CreateConfigmap

func (cc *ConfigmapCreator) CreateConfigmap(ctx context.Context, rawYaml []byte, namespace string, owner *appsv1.Deployment) error

type CrdCreator

type CrdCreator struct {
	// contains filtered or unexported fields
}

func NewCrdCreator

func NewCrdCreator(ctx context.Context, apiExtensionsClient apiextensionsclient.Interface, discoveryClient discovery.DiscoveryInterface, logger logr.Logger) *CrdCreator

type WebhookCreator

type WebhookCreator struct {
	// contains filtered or unexported fields
}

func NewWebhookCreator

func NewWebhookCreator(client kubernetes.Interface, certs *Cert, logger logr.Logger, scheme *runtime.Scheme) *WebhookCreator

func (*WebhookCreator) CreateValidatingWebhookConfigurationFromFile

func (wc *WebhookCreator) CreateValidatingWebhookConfigurationFromFile(ctx context.Context, rawYaml []byte, namespace string, owner v1.Object, watchNamespace bool) error

func (*WebhookCreator) CreateWebhookServiceFromFile

func (wc *WebhookCreator) CreateWebhookServiceFromFile(ctx context.Context, rawYaml []byte, namespace string, owner *appsv1.Deployment) error

Jump to

Keyboard shortcuts

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