Documentation
¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the delivery v1alpha1 API group +kubebuilder:object:generate=true +groupName=delivery.crd-bootstrap
Index ¶
- Constants
- Variables
- type Bootstrap
- func (in *Bootstrap) DeepCopy() *Bootstrap
- func (in *Bootstrap) DeepCopyInto(out *Bootstrap)
- func (in *Bootstrap) DeepCopyObject() runtime.Object
- func (in *Bootstrap) GetConditions() []metav1.Condition
- func (in *Bootstrap) GetRequeueAfter() time.Duration
- func (in *Bootstrap) SetConditions(conditions []metav1.Condition)
- type BootstrapList
- type BootstrapSpec
- type BootstrapStatus
- type ConfigMap
- type GitHub
- type GitLab
- type Helm
- type KubeConfig
- type Source
- type URL
- type Version
Constants ¶
const ( // UsernameKey represents the name of the key for username field. UsernameKey = "username" // PasswordKey represents the name of the key for password field. PasswordKey = "password" // DockerJSONConfigKey represents the name of the key for dockerjsonconfig field. DockerJSONConfigKey = ".dockerconfigjson" )
const (
BootstrapOwnerLabelKey = "delivery.crd-bootstrap.owned"
)
const (
LogLevelDebug = 4
)
Variables ¶
var ( // GroupVersion is group version used to register these objects. GroupVersion = schema.GroupVersion{Group: "delivery.crd-bootstrap", Version: "v1alpha1"} // SchemeBuilder is used to add go types to the GroupVersionKind scheme. SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion} // AddToScheme adds the types in this group-version to the given scheme. AddToScheme = SchemeBuilder.AddToScheme )
Functions ¶
This section is empty.
Types ¶
type Bootstrap ¶
type Bootstrap struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec BootstrapSpec `json:"spec,omitempty"`
Status BootstrapStatus `json:"status,omitempty"`
}
Bootstrap is the Schema for the bootstraps API.
func (*Bootstrap) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Bootstrap.
func (*Bootstrap) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Bootstrap) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*Bootstrap) GetConditions ¶
GetConditions returns the conditions of the ComponentVersion.
func (*Bootstrap) GetRequeueAfter ¶
GetRequeueAfter returns the duration after which the ComponentVersion must be reconciled again.
func (*Bootstrap) SetConditions ¶
SetConditions sets the conditions of the ComponentVersion.
type BootstrapList ¶
type BootstrapList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []Bootstrap `json:"items"`
}
BootstrapList contains a list of Bootstrap.
func (*BootstrapList) DeepCopy ¶
func (in *BootstrapList) DeepCopy() *BootstrapList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BootstrapList.
func (*BootstrapList) DeepCopyInto ¶
func (in *BootstrapList) DeepCopyInto(out *BootstrapList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*BootstrapList) DeepCopyObject ¶
func (in *BootstrapList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type BootstrapSpec ¶
type BootstrapSpec struct {
// Interval defines the regular interval at which a poll for new version should happen.
// +optional
Interval metav1.Duration `json:"interval,omitempty"`
// Source defines a reference to a source which will provide a CRD based on some contract.
// +required
Source *Source `json:"source"`
// Version defines constraints for sources to check against. It can either be a semver constraint or a Digest
// in case of URLs. If a digest is defined, URL sync will ONLY SYNC that digest. If the digest
// differs, it will NOT install it.
// +optional
Version Version `json:"version,omitempty"`
// Template defines a set of values to test a new version against.
// +optional
Template map[string]*apiextensionsv1.JSON `json:"template,omitempty"`
// ContinueOnValidationError will still apply a CRD even if the validation failed for it.
// +optional
ContinueOnValidationError bool `json:"continueOnValidationError,omitempty"`
// Prune will clean up all applied objects once the Bootstrap object is removed.
// +optional
Prune bool `json:"prune,omitempty"`
// KubeConfig defines a kubeconfig that could be used to access another cluster and apply a CRD there.
// +optional
KubeConfig *KubeConfig `json:"kubeConfig,omitempty"`
}
BootstrapSpec defines the desired state of Bootstrap.
func (*BootstrapSpec) DeepCopy ¶
func (in *BootstrapSpec) DeepCopy() *BootstrapSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BootstrapSpec.
func (*BootstrapSpec) DeepCopyInto ¶
func (in *BootstrapSpec) DeepCopyInto(out *BootstrapSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type BootstrapStatus ¶
type BootstrapStatus struct {
// ObservedGeneration is the last reconciled generation.
// +optional
ObservedGeneration int64 `json:"observedGeneration,omitempty"`
// Conditions contains the conditions of this object.
// +optional
// +kubebuilder:printcolumn:name="Ready",type="string",JSONPath=".status.conditions[?(@.type==\"Ready\")].status",description=""
// +kubebuilder:printcolumn:name="Status",type="string",JSONPath=".status.conditions[?(@.type==\"Ready\")].message",description=""
Conditions []metav1.Condition `json:"conditions,omitempty"`
// LastAppliedCRDNames contains the names of the last applied CRDs and the number of times they were applied.
// +optional
LastAppliedCRDNames map[string]int `json:"lastAppliedCRDNames,omitempty"`
// LastAttemptedRevision contains the version or the digest that was tried to be applied and was either successful or failed.
// +optional
LastAttemptedRevision string `json:"lastAttemptedRevision,omitempty"`
// LastAppliedRevision version is the version or the digest that was successfully applied.
// +optional
LastAppliedRevision string `json:"lastAppliedRevision,omitempty"`
}
BootstrapStatus defines the observed state of Bootstrap.
func (*BootstrapStatus) DeepCopy ¶
func (in *BootstrapStatus) DeepCopy() *BootstrapStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BootstrapStatus.
func (*BootstrapStatus) DeepCopyInto ¶
func (in *BootstrapStatus) DeepCopyInto(out *BootstrapStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ConfigMap ¶
type ConfigMap struct {
// Name of the config map.
// +required
Name string `json:"name"`
// Namespace of the config map.
// +required
Namespace string `json:"namespace"`
}
ConfigMap defines a reference to a configmap which hold the CRD information. Version is taken from a version field.
func (*ConfigMap) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigMap.
func (*ConfigMap) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type GitHub ¶
type GitHub struct {
// BaseURL is used for the GitHub url. Defaults to github.com if not defined.
// +optional
BaseURL string `json:"baseURL,omitempty"`
// BaseAPIURL is used for the GitHub API url. Defaults to api.github.com if not defined.
// +optional
BaseAPIURL string `json:"baseAPIURL,omitempty"`
// Owner defines the owner of the repository.
// +required
Owner string `json:"owner"`
// Repo defines the name of the repository.
// +required
Repo string `json:"repo"`
// SecretRef contains a pointed to a Token in case the repository is private.
// +optional
SecretRef *v1.LocalObjectReference `json:"secretRef,omitempty"`
// Manifest defines the name of the manifest that contains the CRD definitions on the GitHub release page.
// +required
Manifest string `json:"manifest"`
}
GitHub defines a GitHub type source where the CRD is coming from `release` section of a GitHub repository.
func (*GitHub) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GitHub.
func (*GitHub) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type GitLab ¶ added in v0.6.0
type GitLab struct {
// BaseAPIURL is used for the GitLab API url. Defaults to api.github.com if not defined.
// +optional
BaseAPIURL string `json:"baseAPIURL,omitempty"`
// Owner defines the owner of the repository. Otherwise, known as Namespace.
// +required
Owner string `json:"owner"`
// Repo defines the name of the repository.
// +required
Repo string `json:"repo"`
// SecretRef contains a pointed to a Token in case the repository is private.
// +optional
SecretRef *v1.LocalObjectReference `json:"secretRef,omitempty"`
// Manifest defines the name of the manifest that contains the CRD definitions on the GitLab release page.
// +required
Manifest string `json:"manifest"`
}
GitLab defines a GitLab type source where the CRD is coming from `release` section of a GitLab repository. https://docs.gitlab.com/ee/api/releases/index.html
func (*GitLab) DeepCopy ¶ added in v0.6.0
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GitLab.
func (*GitLab) DeepCopyInto ¶ added in v0.6.0
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Helm ¶ added in v0.5.0
type Helm struct {
// ChartReference is the location of the helm chart.
// The scheme must be either HTTP or OCI.
// [chart URL | repo/chartname]
// +required
ChartReference string `json:"chartReference"`
// ChartName defines the name of the chart to fetch from the reference URL.
// +required
ChartName string `json:"chartName"`
// Insecure defines
// SecretRef contains a pointer to a secret that contains any needed credentials to access the helm repository.
// +optional
SecretRef *v1.LocalObjectReference `json:"secretRef,omitempty"`
}
Helm defines a Helm type source where the CRD is coming from a helm release with a version.
func (*Helm) DeepCopy ¶ added in v0.5.0
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Helm.
func (*Helm) DeepCopyInto ¶ added in v0.5.0
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type KubeConfig ¶ added in v0.9.0
type KubeConfig struct {
// ServiceAccount defines any custom service accounts to use in order to
// apply crds in a remote cluster.
ServiceAccount string `json:"serviceAccount,omitempty"`
// SecretRef defines a secret with the key in which the kubeconfig is in.
// +optional
SecretRef *meta.KubeConfigReference `json:"secretRef,omitempty"`
// Namespace defines an optional namespace where the KubeConfig should be at.
Namespace string `json:"namespace,omitempty"`
}
KubeConfig defines as way to access a remote cluster.
func (*KubeConfig) DeepCopy ¶ added in v0.9.0
func (in *KubeConfig) DeepCopy() *KubeConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KubeConfig.
func (*KubeConfig) DeepCopyInto ¶ added in v0.9.0
func (in *KubeConfig) DeepCopyInto(out *KubeConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Source ¶
type Source struct {
// GitHub type source.
// +optional
GitHub *GitHub `json:"github,omitempty"`
// GitLab type source.
// +optional
GitLab *GitLab `json:"gitlab,omitempty"`
// Helm type source.
// +optional
Helm *Helm `json:"helm,omitempty"`
// ConfigMap type source.
// +optional
ConfigMap *ConfigMap `json:"configMap,omitempty"`
// URL type source.
// +optional
URL *URL `json:"url,omitempty"`
}
Source defines options from where to fetch CRD content.
func (*Source) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Source.
func (*Source) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type URL ¶
type URL struct {
// URL defines the URL from which do download the YAML content from.
// +required
URL string `json:"url"`
// SecretRef contains a pointed to a Token in case the URL isn't public.
// +optional
SecretRef *v1.LocalObjectReference `json:"secretRef,omitempty"`
}
URL holds a URL from which to fetch the CRD. Version is defined through the digest of the content.
func (*URL) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new URL.
func (*URL) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Version ¶
type Version struct {
// Semver defines a possible constraint like `>=v1`.
// +optional
Semver string `json:"semver,omitempty"`
// Digest defines the digest of the content pointing to a URL.
// +optional
Digest string `json:"digest,omitempty"`
}
Version defines options to look at when trying to determine what version is allowed to be fetched / applied.
func (*Version) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Version.
func (*Version) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.