Documentation
¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the argocd-image-updater v1alpha1 API group +kubebuilder:object:generate=true +groupName=argocd-image-updater.argoproj.io
Index ¶
- Variables
- type ApplicationRef
- type CommonUpdateSettings
- type GitConfig
- type HelmTarget
- type ImageApplicationLastUpdated
- type ImageConfig
- type ImageStatus
- type ImageUpdater
- type ImageUpdaterList
- type ImageUpdaterSpec
- type ImageUpdaterStatus
- type KustomizeTarget
- type ManifestTarget
- type WriteBackConfig
Constants ¶
This section is empty.
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "argocd-image-updater.argoproj.io", 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 ApplicationRef ¶
type ApplicationRef struct {
// NamePattern indicates the glob pattern for application name
// +kubebuilder:validation:Required
NamePattern string `json:"namePattern"`
// LabelSelectors indicates the label selectors to apply for application selection
// +optional
LabelSelectors *metav1.LabelSelector `json:"labelSelectors,omitempty"`
// CommonUpdateSettings overrides the global CommonUpdateSettings for applications
// matched by this selector.
// +optional
*CommonUpdateSettings `json:"commonUpdateSettings,omitempty"`
// WriteBackConfig overrides the global WriteBackConfig settings for applications
// matched by this selector.
// +optional
*WriteBackConfig `json:"writeBackConfig,omitempty"`
// Images contains a list of configurations that how images should be updated.
// These rules apply to applications selected by namePattern in ApplicationRefs, and each
// image can override global/ApplicationRef settings.
// +kubebuilder:validation:MinItems=1
// +listType=map
// +listMapKey=alias
Images []ImageConfig `json:"images"`
}
ApplicationRef contains various criteria by which to include applications for managing by image updater
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 CommonUpdateSettings ¶
type CommonUpdateSettings struct {
// UpdateStrategy defines the update strategy to apply.
// Examples: "semver", "latest", "digest", "name".
// This acts as the default if not overridden at a more specific level.
// +optional
// +kubebuilder:default:="semver"
UpdateStrategy *string `json:"updateStrategy,omitempty"`
// ForceUpdate specifies whether updates should be forced.
// This acts as the default if not overridden.
// +optional
// +kubebuilder:default:=false
ForceUpdate *bool `json:"forceUpdate,omitempty"`
// AllowTags is a regex pattern for tags to allow.
// This acts as the default if not overridden.
// +optional
AllowTags *string `json:"allowTags,omitempty"`
// IgnoreTags is a list of glob-like patterns of tags to ignore.
// This acts as the default and can be overridden at more specific levels.
// +listType=atomic
// +optional
IgnoreTags []string `json:"ignoreTags,omitempty"`
// PullSecret is the pull secret to use for images.
// This acts as the default if not overridden.
// +optional
PullSecret *string `json:"pullSecret,omitempty"`
// Platforms specifies a list of target platforms (e.g., "linux/amd64", "linux/arm64").
// If specified, the image updater will consider these platforms when checking for new versions or digests.
// +listType=atomic
// +optional
Platforms []string `json:"platforms,omitempty"`
}
CommonUpdateSettings groups common update strategy settings that can be applied globally, per ApplicationRef, or per ImageConfig.
func (*CommonUpdateSettings) DeepCopy ¶
func (in *CommonUpdateSettings) DeepCopy() *CommonUpdateSettings
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CommonUpdateSettings.
func (*CommonUpdateSettings) DeepCopyInto ¶
func (in *CommonUpdateSettings) DeepCopyInto(out *CommonUpdateSettings)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type GitConfig ¶
type GitConfig struct {
// Repository URL to commit changes to.
// If not specified here or at the spec level, the controller MUST infer it from the
// Argo CD Application's `spec.source.repoURL`. This field allows overriding that.
// +optional
Repository *string `json:"repository,omitempty"`
// Branch to commit updates to.
// Required if write-back method is Git and this is not specified at the spec level.
// +optional
Branch *string `json:"branch,omitempty"`
// WriteBackTarget defines the path and type of file to update in the Git repository.
// Examples: "helmvalues:./helm/values.yaml", "kustomization:./kustomize/overlays/production".
// For ApplicationSet usage, `{{ .app.path.path }}` should be resolved by ApplicationSet
// before this CR is generated, resulting in a concrete path here.
// Required if write-back method is Git and this is not specified at the spec level.
// +optional
WriteBackTarget *string `json:"writeBackTarget,omitempty"`
}
GitConfig defines parameters for Git interaction when `writeBackMethod` involves Git.
func (*GitConfig) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GitConfig.
func (*GitConfig) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type HelmTarget ¶
type HelmTarget struct {
// Name is the dot-separated path to the Helm key for the image repository/name part.
// Example: "image.repository", "frontend.deployment.image.name".
// This field is required if the Helm target is used.
Name *string `json:"name"`
// Tag is the dot-separated path to the Helm key for the image tag part.
// Example: "image.tag", "frontend.deployment.image.version".
// This field is required if the Helm target is used.
Tag *string `json:"tag"`
// Spec is an optional dot-separated path to a Helm key where the full image string
// (e.g., "image/name:1.0") should be written.
// Use this if your Helm chart expects the entire image reference in a single field,
// rather than separate name/tag fields. If this is set, other Helm parameter-related
// options will be ignored.
// +optional
Spec *string `json:"spec,omitempty"`
}
HelmTarget defines parameters for updating image references within Helm values.
func (*HelmTarget) DeepCopy ¶
func (in *HelmTarget) DeepCopy() *HelmTarget
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HelmTarget.
func (*HelmTarget) DeepCopyInto ¶
func (in *HelmTarget) DeepCopyInto(out *HelmTarget)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ImageApplicationLastUpdated ¶
type ImageApplicationLastUpdated struct {
// AppName indicates and namespace and the application name
AppName string `json:"appName"`
// LastUpdatedAt indicates when the image in this application was last updated
LastUpdatedAt metav1.Time `json:"lastUpdatedAt,omitempty"`
}
ImageApplicationLastUpdated contains information for an application and when the image was last updated therein
func (*ImageApplicationLastUpdated) DeepCopy ¶
func (in *ImageApplicationLastUpdated) DeepCopy() *ImageApplicationLastUpdated
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImageApplicationLastUpdated.
func (*ImageApplicationLastUpdated) DeepCopyInto ¶
func (in *ImageApplicationLastUpdated) DeepCopyInto(out *ImageApplicationLastUpdated)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ImageConfig ¶
type ImageConfig struct {
// Alias is a short, user-defined name for this image configuration.
// It MUST be unique within a single ApplicationRef's list of images.
// This field is mandatory.
// +kubebuilder:validation:Required
// +kubebuilder:validation:Pattern=`^[a-zA-Z0-9][a-zA-Z0-9-._]*$`
Alias string `json:"alias"`
// ImageName is the full identifier of the image to be tracked,
// including the registry (if not Docker Hub), the image name, and an initial/current tag or version.
// This is the string used to query the container registry and also as a base for finding updates.
// Example: "docker.io/library/nginx:1.17.10", "quay.io/prometheus/node-exporter:v1.5.0".
// This field is mandatory.
// +kubebuilder:validation:Required
ImageName string `json:"imageName"`
// CommonUpdateSettings overrides the effective default CommonUpdateSettings for this specific image.
// +optional
*CommonUpdateSettings `json:"commonUpdateSettings,omitempty"`
// ManifestTarget defines how and where to update this image in Kubernetes manifests.
// Only one of Helm or Kustomize should be specified within this block.
// This whole block is optional if the image update isn't written to a manifest in a structured way.
// +optional
*ManifestTarget `json:"manifestTargets,omitempty"`
}
ImageConfig defines how a specific container image should be discovered, updated, and how those updates should be reflected in application manifests.
func (*ImageConfig) DeepCopy ¶
func (in *ImageConfig) DeepCopy() *ImageConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImageConfig.
func (*ImageConfig) DeepCopyInto ¶
func (in *ImageConfig) DeepCopyInto(out *ImageConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ImageStatus ¶
type ImageStatus struct {
// Name indicates the image name
Name string `json:"name"`
// Version indicates the image version
Version string `json:"version"`
// Applications contains a list of applications and when the image was last updated therein
Applications []ImageApplicationLastUpdated `json:"applications,omitempty"`
}
ImageStatus contains information for an image:version and its update status in hosting applications
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.
type ImageUpdater ¶
type ImageUpdater struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec ImageUpdaterSpec `json:"spec,omitempty"`
Status ImageUpdaterStatus `json:"status,omitempty"`
}
ImageUpdater is the Schema for the imageupdaters API
func (*ImageUpdater) DeepCopy ¶
func (in *ImageUpdater) DeepCopy() *ImageUpdater
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImageUpdater.
func (*ImageUpdater) DeepCopyInto ¶
func (in *ImageUpdater) DeepCopyInto(out *ImageUpdater)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ImageUpdater) DeepCopyObject ¶
func (in *ImageUpdater) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ImageUpdaterList ¶
type ImageUpdaterList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []ImageUpdater `json:"items"`
}
ImageUpdaterList contains a list of ImageUpdater
func (*ImageUpdaterList) DeepCopy ¶
func (in *ImageUpdaterList) DeepCopy() *ImageUpdaterList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImageUpdaterList.
func (*ImageUpdaterList) DeepCopyInto ¶
func (in *ImageUpdaterList) DeepCopyInto(out *ImageUpdaterList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ImageUpdaterList) DeepCopyObject ¶
func (in *ImageUpdaterList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ImageUpdaterSpec ¶
type ImageUpdaterSpec struct {
// Namespace indicates the target namespace of the applications.
// This is the namespace where the controller will look for Argo CD Applications
// matching the criteria in ApplicationRefs.
// +kubebuilder:validation:Required
Namespace string `json:"namespace"`
// CommonUpdateSettings provides global default settings for update strategies,
// tag filtering, pull secrets, etc., for all applications matched by this CR.
// These can be overridden at the ApplicationRef or ImageConfig level.
// +optional
*CommonUpdateSettings `json:"commonUpdateSettings,omitempty"`
// WriteBackConfig provides global default settings for how and where to write back image updates.
// This can be overridden at the ApplicationRef level.
// +optional
*WriteBackConfig `json:"writeBackConfig,omitempty"`
// ApplicationRefs indicates the set of applications to be managed.
// ApplicationRefs is a list of rules to select Argo CD Applications within the `spec.namespace`.
// Each reference can also provide specific overrides for the global settings defined above.
// +kubebuilder:validation:MinItems=1
// +listType=map
// +listMapKey=namePattern
ApplicationRefs []ApplicationRef `json:"applicationRefs"`
}
ImageUpdaterSpec defines the desired state of ImageUpdater It specifies which applications to target, default update strategies, and a list of images to manage.
func (*ImageUpdaterSpec) DeepCopy ¶
func (in *ImageUpdaterSpec) DeepCopy() *ImageUpdaterSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImageUpdaterSpec.
func (*ImageUpdaterSpec) DeepCopyInto ¶
func (in *ImageUpdaterSpec) DeepCopyInto(out *ImageUpdaterSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ImageUpdaterStatus ¶
type ImageUpdaterStatus struct {
// LastUpdatedAt indicates when the image updater last ran
LastUpdatedAt *metav1.Time `json:"reconciledAt,omitempty"`
// ImageStatus indicates the detailed status for the list of managed images
ImageStatus []ImageStatus `json:"imageStatus,omitempty"`
Conditions []metav1.Condition `json:"conditions,omitempty"`
}
ImageUpdaterStatus defines the observed state of ImageUpdater
func (*ImageUpdaterStatus) DeepCopy ¶
func (in *ImageUpdaterStatus) DeepCopy() *ImageUpdaterStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ImageUpdaterStatus.
func (*ImageUpdaterStatus) DeepCopyInto ¶
func (in *ImageUpdaterStatus) DeepCopyInto(out *ImageUpdaterStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type KustomizeTarget ¶
type KustomizeTarget struct {
// Name is the image name (which can include the registry and an initial tag)
// as it appears in the `images` list of a kustomization.yaml file that needs to be updated.
// The updater will typically change the tag or add a digest to this entry.
// Example: "docker.io/library/nginx".
// This field is required if the Kustomize target is used.
Name *string `json:"name"`
}
KustomizeTarget defines parameters for updating image references within Kustomize configurations.
func (*KustomizeTarget) DeepCopy ¶
func (in *KustomizeTarget) DeepCopy() *KustomizeTarget
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KustomizeTarget.
func (*KustomizeTarget) DeepCopyInto ¶
func (in *KustomizeTarget) DeepCopyInto(out *KustomizeTarget)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ManifestTarget ¶
type ManifestTarget struct {
// Helm specifies update parameters if the target manifest is managed by Helm
// and updates are to be made to Helm values files.
// +optional
Helm *HelmTarget `json:"helm,omitempty"`
// Kustomize specifies update parameters if the target manifest is managed by Kustomize
// and updates involve changing image tags in Kustomize configurations.
// +optional
Kustomize *KustomizeTarget `json:"kustomize,omitempty"`
}
ManifestTarget specifies the mechanism and details for updating image references in application manifests. Only one of the fields (Helm, Kustomize) should be set, dictating the update method. +kubebuilder:validation:XValidation:rule="has(self.helm) ? !has(self.kustomize) : has(self.kustomize)",message="Exactly one of helm or kustomize must be specified within manifestTargets if the block is present."
func (*ManifestTarget) DeepCopy ¶
func (in *ManifestTarget) DeepCopy() *ManifestTarget
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ManifestTarget.
func (*ManifestTarget) DeepCopyInto ¶
func (in *ManifestTarget) DeepCopyInto(out *ManifestTarget)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type WriteBackConfig ¶
type WriteBackConfig struct {
// Method defines the method for writing back updated image versions.
// This acts as the default if not overridden. If not specified, defaults to "argocd".
// +kubebuilder:validation:Required
// +kubebuilder:default:="argocd"
// +kubebuilder:validation:Pattern=`^(argocd|git|git:[a-zA-Z0-9][a-zA-Z0-9-._/:]*)$`
Method *string `json:"method,omitempty"`
// GitConfig provides Git configuration settings if the write-back method involves Git.
// This can only be used when method is "git" or starts with "git:".
// +optional
*GitConfig `json:"gitConfig,omitempty"`
}
WriteBackConfig defines how and where to write back image updates. It includes the method (e.g., git, direct Application update) and specific configurations for that method, like Git settings.
func (*WriteBackConfig) DeepCopy ¶
func (in *WriteBackConfig) DeepCopy() *WriteBackConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WriteBackConfig.
func (*WriteBackConfig) DeepCopyInto ¶
func (in *WriteBackConfig) DeepCopyInto(out *WriteBackConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.