v1

package
v2.19.2 Latest Latest
Warning

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

Go to latest
Published: Feb 24, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

+groupName=apps.kubermatic.k8c.io +versionName=v1 +kubebuilder:object:generate=true

Index

Constants

View Source
const GroupName = "apps.kubermatic.k8c.io"

GroupName is the group name use in this package

View Source
const GroupVersion = "v1"

Variables

View Source
var (
	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
	AddToScheme   = SchemeBuilder.AddToScheme
)
View Source
var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: GroupVersion}

SchemeGroupVersion is group version used to register these objects

Functions

func Resource

func Resource(resource string) schema.GroupResource

Resource takes an unqualified resource and returns a Group qualified GroupResource

Types

type ApplicationConstraints

type ApplicationConstraints struct {
	// Version of K8s version that a user cluster must satisfy for the application to be installed.
	// Wildcards are allowed  e.g. "1.18.*"
	// Range are allowed e.g." >= 1.19.0, < 1.19.15"
	K8sVersion VersionConstraints `json:"k8sVersion,omitempty"`

	// Version of KKP version that a user cluster must satisfy for the application to be installed.
	// Wildcards are allowed  e.g. "2.18.*"
	// Range are allowed e.g.">= 2.16, < 2.18.0"
	KKPVersion VersionConstraints `json:"kkpVersion,omitempty"`
}

func (*ApplicationConstraints) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationConstraints.

func (*ApplicationConstraints) DeepCopyInto

func (in *ApplicationConstraints) DeepCopyInto(out *ApplicationConstraints)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ApplicationDefinition

type ApplicationDefinition struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec ApplicationDefinitionSpec `json:"spec,omitempty"`
}

ApplicationDefinition is the Schema for the applicationdefinitions API

func (*ApplicationDefinition) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationDefinition.

func (*ApplicationDefinition) DeepCopyInto

func (in *ApplicationDefinition) DeepCopyInto(out *ApplicationDefinition)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ApplicationDefinition) DeepCopyObject

func (in *ApplicationDefinition) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApplicationDefinitionList

type ApplicationDefinitionList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []ApplicationDefinition `json:"items"`
}

ApplicationDefinitionList contains a list of ApplicationDefinition

func (*ApplicationDefinitionList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationDefinitionList.

func (*ApplicationDefinitionList) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ApplicationDefinitionList) DeepCopyObject

func (in *ApplicationDefinitionList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApplicationDefinitionSpec

type ApplicationDefinitionSpec struct {
	// Description of the application. what is its purpose
	Description string `json:"description"`

	// available version for this application
	Versions []ApplicationVersion `json:"versions"`
}

ApplicationDefinitionSpec defines the desired state of ApplicationDefinition

func (*ApplicationDefinitionSpec) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationDefinitionSpec.

func (*ApplicationDefinitionSpec) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ApplicationInstallation

type ApplicationInstallation struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   ApplicationInstallationSpec   `json:"spec,omitempty"`
	Status ApplicationInstallationStatus `json:"status,omitempty"`
}

ApplicationInstallation describes a single installation of an Application

func (*ApplicationInstallation) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationInstallation.

func (*ApplicationInstallation) DeepCopyInto

func (in *ApplicationInstallation) DeepCopyInto(out *ApplicationInstallation)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ApplicationInstallation) DeepCopyObject

func (in *ApplicationInstallation) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApplicationInstallationCondition

type ApplicationInstallationCondition struct {
	// Type of cluster condition.
	Type ApplicationInstallationConditionType `json:"type"`
	// Status of the condition, one of True, False, Unknown.
	Status corev1.ConditionStatus `json:"status"`
	// (brief) reason for the condition's last transition.
	Reason string `json:"reason,omitempty"`
	// Human readable message indicating details about last transition.
	Message string `json:"message,omitempty"`
}

func (*ApplicationInstallationCondition) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationInstallationCondition.

func (*ApplicationInstallationCondition) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ApplicationInstallationConditionType

type ApplicationInstallationConditionType string

+kubebuilder:validation:Enum=ManifestsRetrieved;ManifestsApplied;Ready

const (
	// ManifestsRetrieved indicates all necessary manifests have been fetched from the external source
	ManifestsRetrieved ApplicationInstallationConditionType = "ManifestsRetrieved"
	// ManifestsApplied indicates that all manifests have been applied in the target user-cluster
	ManifestsApplied ApplicationInstallationConditionType = "ManifestsApplied"
	// Ready describes all components have been successfully rolled out and are ready
	Ready ApplicationInstallationConditionType = "Ready"
)

type ApplicationInstallationList

type ApplicationInstallationList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`

	Items []ApplicationInstallation `json:"items"`
}

ApplicationInstallationList is a list of ApplicationInstallations

func (*ApplicationInstallationList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationInstallationList.

func (*ApplicationInstallationList) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ApplicationInstallationList) DeepCopyObject

func (in *ApplicationInstallationList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApplicationInstallationSpec

type ApplicationInstallationSpec struct {
	// TargetNamespace is the namespace to deploy the Application into
	TargetNamespace string `json:"targetNamespace"`

	// +kubebuilder:default:=true
	// CreateNamespace defines whether the namespace should be created if it does not exist. Defaults to true
	CreateNamespace bool `json:"createNamespace"`

	// ApplicationRef is a reference to identify which Application should be deployed
	ApplicationRef ApplicationRef `json:"applicationRef"`

	// Values describe overrides for manifest-rendering
	Values json.RawMessage `json:"values,omitempty"`
}

func (*ApplicationInstallationSpec) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationInstallationSpec.

func (*ApplicationInstallationSpec) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ApplicationInstallationStatus

type ApplicationInstallationStatus struct {
	LastUpdated metav1.Time `json:"lastUpdated,omitempty"`
	// Conditions contains conditions an installation is in, its primary use case is status signaling between controllers or between controllers and the API
	Conditions []ApplicationInstallationCondition `json:"conditions,omitempty"`
}

ApplicationInstallationStatus denotes status information about an ApplicationInstallation

func (*ApplicationInstallationStatus) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationInstallationStatus.

func (*ApplicationInstallationStatus) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ApplicationRef

type ApplicationRef struct {
	// Name of the Application
	Name string `json:"name"`

	// Version of the Application. Must be a valid SemVer version
	Version Version `json:"version"`
}

ApplicationRef describes a KKP-wide, unique reference to an Application

func (*ApplicationRef) DeepCopy

func (in *ApplicationRef) DeepCopy() *ApplicationRef

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationRef.

func (*ApplicationRef) DeepCopyInto

func (in *ApplicationRef) DeepCopyInto(out *ApplicationRef)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ApplicationSource

type ApplicationSource struct {
	// Get application to install from a Helm repository
	Helm *HelmSource `json:"helm,omitempty"`

	// Get application to install form a Git repository
	Git *GitSource `json:"git,omitempty"`
}

func (*ApplicationSource) DeepCopy

func (in *ApplicationSource) DeepCopy() *ApplicationSource

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationSource.

func (*ApplicationSource) DeepCopyInto

func (in *ApplicationSource) DeepCopyInto(out *ApplicationSource)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ApplicationTemplate

type ApplicationTemplate struct {
	// Defined how the source of the application (e.g Helm chart) are retrieved
	Source ApplicationSource `json:"source"`

	// Method used to install the application
	Method TemplateMethod `json:"method"`

	// Define the valued that can be override for the installation
	FormSpec []FormField `json:"formSpec,omitempty"`
}

func (*ApplicationTemplate) DeepCopy

func (in *ApplicationTemplate) DeepCopy() *ApplicationTemplate

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationTemplate.

func (*ApplicationTemplate) DeepCopyInto

func (in *ApplicationTemplate) DeepCopyInto(out *ApplicationTemplate)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ApplicationVersion

type ApplicationVersion struct {
	// Version of the application (eg v1.2.3)
	Version string `json:"version"`

	// Constraints defined criteria that a user cluster must satisfy for the application to be installed
	Constraints ApplicationConstraints `json:"constraints,omitempty"`

	// Template defines how application is installed (source provenance, Method...)
	Template ApplicationTemplate `json:"template"`
}

func (*ApplicationVersion) DeepCopy

func (in *ApplicationVersion) DeepCopy() *ApplicationVersion

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationVersion.

func (*ApplicationVersion) DeepCopyInto

func (in *ApplicationVersion) DeepCopyInto(out *ApplicationVersion)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FormField

type FormField struct {
	// Type of displayed control
	Type FormFieldType `json:"type"`

	// DisplayName is visible in the UI
	DisplayName string `json:"displayName"`

	// InternalName is used internally to save in the ApplicationInstallation object
	InternalName string `json:"internalName"`

	// HelpText is visible in the UI next to the filed
	HelpText string `json:"helpText,omitempty"`

	// Required indicates if the control has to be set
	Required bool `json:"required,omitempty"`
}

func (*FormField) DeepCopy

func (in *FormField) DeepCopy() *FormField

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FormField.

func (*FormField) DeepCopyInto

func (in *FormField) DeepCopyInto(out *FormField)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FormFieldType

type FormFieldType string

+kubebuilder:validation:Enum=number;boolean;text;text-area

const (
	FormFieldTypeNumber   FormFieldType = "number"
	FormFieldTypeBoolean  FormFieldType = "boolean"
	FormFieldTypeText     FormFieldType = "text"
	FormFieldTypeTextArea FormFieldType = "text-area"
)

type GitAuthMethod

type GitAuthMethod string

+kubebuilder:validation:Enum=password;token;ssh-key

const (
	GitAuthMethodPassword GitAuthMethod = "password"
	GitAuthMethodToken    GitAuthMethod = "token"
	GitAuthMethodSSHKey   GitAuthMethod = "ssh-key"
)

type GitCredentials

type GitCredentials struct {
	// Authentication method
	Method GitAuthMethod `json:"method"`

	// Username holds the ref and key in the secret for the username credential
	Username *GlobalSecretKeySelector `json:"username,omitempty"`

	// Password holds the ref and key in the secret for the Password credential
	Password *GlobalSecretKeySelector `json:"password,omitempty"`

	// Token holds the ref and key in the secret for the token credential
	Token *GlobalSecretKeySelector `json:"token,omitempty"`

	// SSHKey holds the ref and key in the secret for the SshKey credential
	SSHKey *GlobalSecretKeySelector `json:"sshKey,omitempty"`
}

func (*GitCredentials) DeepCopy

func (in *GitCredentials) DeepCopy() *GitCredentials

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GitCredentials.

func (*GitCredentials) DeepCopyInto

func (in *GitCredentials) DeepCopyInto(out *GitCredentials)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type GitSource

type GitSource struct {
	// URL to the repository (e.g. git://host.xz[:port]/path/to/repo.git/)
	Remote string `json:"remote"`

	// Git reference to check out: can be a branch, tag, or sha1
	Ref string `json:"ref"`

	// Path of the "source" in the repository. default is repository root
	Path string `json:"path,omitempty"`

	// Credentials holds the git credentials
	Credentials *GitCredentials `json:"credentials,omitempty"`
}

func (*GitSource) DeepCopy

func (in *GitSource) DeepCopy() *GitSource

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GitSource.

func (*GitSource) DeepCopyInto

func (in *GitSource) DeepCopyInto(out *GitSource)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type GlobalSecretKeySelector

type GlobalSecretKeySelector struct {
	corev1.SecretReference `json:",inline"`
	Key                    string `json:"key"`
}

GlobalSecretKeySelector is needed as we can not use v1.SecretKeySelector because it is not cross namespace

func (*GlobalSecretKeySelector) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GlobalSecretKeySelector.

func (*GlobalSecretKeySelector) DeepCopyInto

func (in *GlobalSecretKeySelector) DeepCopyInto(out *GlobalSecretKeySelector)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type HelmCredentials

type HelmCredentials struct {
	// Username holds the ref and key in the secret for the username credential
	Username GlobalSecretKeySelector `json:"username"`

	// Password holds the ref and key in the secret for the Password credential
	Password GlobalSecretKeySelector `json:"password"`
}

func (*HelmCredentials) DeepCopy

func (in *HelmCredentials) DeepCopy() *HelmCredentials

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HelmCredentials.

func (*HelmCredentials) DeepCopyInto

func (in *HelmCredentials) DeepCopyInto(out *HelmCredentials)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type HelmSource

type HelmSource struct {
	// URl of the helm repository
	URL string `json:"url"`

	// Name of the Chart
	ChartName string `json:"chartName"`

	// Version of the Chart
	ChartVersion string `json:"chartVersion"`

	// Credentials hold the ref to the secret with helm credentials
	Credentials *HelmCredentials `json:"credentials,omitempty"`
}

func (*HelmSource) DeepCopy

func (in *HelmSource) DeepCopy() *HelmSource

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HelmSource.

func (*HelmSource) DeepCopyInto

func (in *HelmSource) DeepCopyInto(out *HelmSource)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type TemplateMethod

type TemplateMethod string

+kubebuilder:validation:Enum=helm

const (
	HelmTemplateMethod TemplateMethod = "helm"
)

type Version

type Version struct {
	semverlib.Version
}

Version wraps semverlib.Version. It is needed because kubebuilder does not accept structs with non-tagged fields, even if they have custom marshallers With this the CRD resource will have Version as string but operator code can work directly with the semverlib.Version struct (taken from https://github.com/kubernetes-sigs/controller-tools/blob/master/pkg/crd/testdata/cronjob_types.go#L283)

func (*Version) DeepCopy

func (in *Version) DeepCopy() *Version

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Version.

func (*Version) DeepCopyInto

func (in *Version) DeepCopyInto(out *Version)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type VersionConstraints

type VersionConstraints string

func (VersionConstraints) SemverConstraints

func (c VersionConstraints) SemverConstraints() (*semverlib.Constraints, error)

Jump to

Keyboard shortcuts

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