Documentation ¶
Overview ¶
Package v1alpha2 contains API Schema definitions for the image-builder v1alpha2 API group +kubebuilder:object:generate=true +groupName=image-builder.anza-labs.dev
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( // GroupVersion is group version used to register these objects. GroupVersion = schema.GroupVersion{Group: "image-builder.anza-labs.dev", Version: "v1alpha2"} // 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 AdditionalData ¶
type AdditionalData struct { // Name specifies unique name for the additional data. // +required Name string `json:"name"` // VolumeMountPoint specifies the path where this data should be mounted. // +required VolumeMountPoint string `json:"volumeMountPoint"` // DataSource specifies the data source details. DataSource `json:",inline"` }
AdditionalData represents additional data sources for image building.
func (*AdditionalData) DeepCopy ¶
func (in *AdditionalData) DeepCopy() *AdditionalData
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AdditionalData.
func (*AdditionalData) DeepCopyInto ¶
func (in *AdditionalData) DeepCopyInto(out *AdditionalData)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type BucketDataSource ¶
type BucketDataSource struct { // Credentials is a reference to the credentials for accessing the bucket. // +required Credentials *corev1.LocalObjectReference `json:"credentials"` // Items specifies specific items within the bucket to include. // +optional Items []corev1.KeyToPath `json:"items,omitempty"` // ItemsSecret specifies a Scret mapping item names to object storage keys. // Each value should either be a key of the object or follow the format "key = <Presigned URL>", // e.g.: // item-1: "path/to/item-1 = <Presigned URL>" // item-2: "path/to/item-2" // +optional ItemsSecret *corev1.LocalObjectReference `json:"itemsConfigMap,omitempty"` }
BucketDataSource represents an S3 bucket data source.
func (*BucketDataSource) DeepCopy ¶
func (in *BucketDataSource) DeepCopy() *BucketDataSource
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BucketDataSource.
func (*BucketDataSource) DeepCopyInto ¶
func (in *BucketDataSource) DeepCopyInto(out *BucketDataSource)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Container ¶
type Container struct { // Image indicates the container image to use for the init container. // +optional Image string `json:"image,omitempty"` // Verbosity specifies the log verbosity level for the container. // +optional // +default=4 // +kubebuilder:default=4 // +kubebuilder:validation:Minimum=0 // +kubebuilder:validation:Maximum=10 Verbosity uint8 `json:"verbosity"` // Resources describe the compute resource requirements for the builder job. // +optional Resources corev1.ResourceRequirements `json:"resources,omitempty"` }
func (*Container) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Container.
func (*Container) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DataSource ¶
type DataSource struct { // ConfigMap specifies a ConfigMap as a data source. // +optional ConfigMap *corev1.ConfigMapVolumeSource `json:"configMap,omitempty"` // Secret specifies a Secret as a data source. // +optional Secret *corev1.SecretVolumeSource `json:"secret,omitempty"` // Image specifies a container image as a data source. // +optional Image *corev1.ImageVolumeSource `json:"image,omitempty"` // Volume specifies a PersistentVolumeClaim as a data source. // +optional Volume *corev1.PersistentVolumeClaimVolumeSource `json:"volume,omitempty"` // Bucket specifies an S3 bucket as a data source. // +optional Bucket *BucketDataSource `json:"bucket,omitempty"` // GitRepository specifies a Git repository as a data source. // +optional GitRepository *GitRepository `json:"gitRepository,omitempty"` }
DataSource defines the available sources for additional data. Each data source is either used directly as a Volume for the image, or will be fetched into empty dir shared between init container and the builder.
func (*DataSource) DeepCopy ¶
func (in *DataSource) DeepCopy() *DataSource
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DataSource.
func (*DataSource) DeepCopyInto ¶
func (in *DataSource) DeepCopyInto(out *DataSource)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type GitRepository ¶
type GitRepository struct { // Repository specifies the URL of the Git repository. // +required Repository string `json:"repository"` // Ref specifies the branch, tag, or commit hash to be used from the Git repository. // +optional // +default="main" Ref string `json:"ref"` // Credentials specifies the credentials for accessing the repository. // Secret must be one of the following types: // - "kubernetes.io/basic-auth" with "username" and "password" fields; // - "kubernetes.io/ssh-auth" with "ssh-privatekey" field; // - "Opaque" with "gitconfig" field. // +optional Credentials *corev1.LocalObjectReference `json:"credentials,omitempty"` }
GitRepository represents a Git repository data source.
func (*GitRepository) DeepCopy ¶
func (in *GitRepository) DeepCopy() *GitRepository
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GitRepository.
func (*GitRepository) DeepCopyInto ¶
func (in *GitRepository) DeepCopyInto(out *GitRepository)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Image ¶
type Image struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec ImageSpec `json:"spec,omitempty"` Status ImageStatus `json:"status,omitempty"` }
Image represents the schema for the images API.
func (*Image) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Image.
func (*Image) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Image) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ImageList ¶
type ImageList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []Image `json:"items"` }
ImageList contains a list of Image resources.
func (*ImageList) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImageList.
func (*ImageList) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ImageList) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ImageSpec ¶
type ImageSpec struct { // Builder specifies the parameters for the main container configuration. // +optional Builder Container `json:"builder,omitempty"` // ObjFetcher specifies the parameters for the Object Fetcher init container configuration. // +optional ObjFetcher Container `json:"objFetcher,omitempty"` // GitFetcher specifies the parameters for the Git Fetcher init container configuration. // +optional GitFetcher Container `json:"gitFetcher,omitempty"` // Affinity specifies the scheduling constraints for Pods running the builder job. // +optional Affinity *corev1.Affinity `json:"affinity,omitempty"` // Format specifies the output image format. // +kubebuilder:validation:Enum=aws;docker;dynamic-vhd;gcp;iso-bios;iso-efi;iso-efi-initrd;kernel+initrd;kernel+iso;kernel+squashfs;qcow2-bios;qcow2-efi;raw-bios;raw-efi;rpi3;tar;tar-kernel-initrd;vhd;vmdk // +required Format string `json:"format"` // Configuration is a YAML-formatted Linuxkit configuration. // +required Configuration string `json:"configuration"` // Result is a reference to the local object containing downloadable build results. // Defaults to the Image.Metadata.Name if not specified. // +optional Result corev1.LocalObjectReference `json:"result"` // BucketCredentials is a reference to the credentials used for storing the image in S3. // +required BucketCredentials corev1.LocalObjectReference `json:"bucketCredentials"` // AdditionalData specifies additional data sources required for building the image. // +optional AdditionalData []AdditionalData `json:"additionalData"` }
ImageSpec defines the desired state of an Image resource.
func (*ImageSpec) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImageSpec.
func (*ImageSpec) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ImageStatus ¶
type ImageStatus struct { // Ready indicates whether the image has been successfully built. // +optional Ready bool `json:"ready"` }
ImageStatus defines the observed state of an Image resource.
func (*ImageStatus) DeepCopy ¶
func (in *ImageStatus) DeepCopy() *ImageStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImageStatus.
func (*ImageStatus) DeepCopyInto ¶
func (in *ImageStatus) DeepCopyInto(out *ImageStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.