v1alpha1

package
v0.16.0 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2020 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package v1alpha1 contains managed resources for AWS ECR services +kubebuilder:object:generate=true +groupName=ecr.aws.crossplane.io +versionName=v1alpha1

Index

Constants

View Source
const (
	Group   = "ecr.aws.crossplane.io"
	Version = "v1alpha1"
)

Package type metadata.

Variables

View Source
var (
	// SchemeGroupVersion is group version used to register these objects
	SchemeGroupVersion = schema.GroupVersion{Group: Group, Version: Version}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: SchemeGroupVersion}
)
View Source
var (
	RepositoryKind             = reflect.TypeOf(Repository{}).Name()
	RepositoryGroupKind        = schema.GroupKind{Group: Group, Kind: RepositoryKind}.String()
	RepositoryKindAPIVersion   = RepositoryKind + "." + SchemeGroupVersion.String()
	RepositoryGroupVersionKind = SchemeGroupVersion.WithKind(RepositoryKind)
)

Repository type metadata.

Functions

func CompareTags

func CompareTags(tags []Tag, ecrTags []ecr.Tag) bool

CompareTags compares arrays of v1alpha1.Tag and ecr.Tag

func DiffTags

func DiffTags(spec []Tag, current []ecr.Tag) (addTags []ecr.Tag, remove []string)

DiffTags returns tags that should be added or removed.

func ECRTagsToMap

func ECRTagsToMap(ecrTags []ecr.Tag) map[string]string

ECRTagsToMap converts []ecr.Tag to map

func GenerateECRTags

func GenerateECRTags(tags []Tag) []ecr.Tag

GenerateECRTags generates a tag array with type that ECR client expects.

func SortTags

func SortTags(tags []Tag, ecrTags []ecr.Tag)

SortTags sorts array of v1alpha1.Tag and ecr.Tag on 'Key'

func TagsToMap

func TagsToMap(tags []Tag) map[string]string

TagsToMap converts []v1alpha1.Tag to map

Types

type ImageScanningConfiguration

type ImageScanningConfiguration struct {

	// The setting that determines whether images are scanned after being pushed
	// to a repository. If set to true, images will be scanned after being pushed.
	// If this parameter is not specified, it will default to false and images will
	// not be scanned unless a scan is manually started with the StartImageScan
	// API.
	ScanOnPush bool `json:"scanOnPush"`
}

ImageScanningConfiguration Scanning Configuration

func (*ImageScanningConfiguration) DeepCopy

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

func (*ImageScanningConfiguration) DeepCopyInto

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

type Repository

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

	Spec   RepositorySpec   `json:"spec"`
	Status RepositoryStatus `json:"status,omitempty"`
}

A Repository is a managed resource that represents an Elastic Container Repository +kubebuilder:printcolumn:name="READY",type="string",JSONPath=".status.conditions[?(@.type=='Ready')].status" +kubebuilder:printcolumn:name="SYNCED",type="string",JSONPath=".status.conditions[?(@.type=='Synced')].status" +kubebuilder:printcolumn:name="ID",type="string",JSONPath=".metadata.annotations.crossplane\\.io/external-name" +kubebuilder:printcolumn:name="URI",type="string",JSONPath=".status.atProvider.repositoryUri" +kubebuilder:subresource:status +kubebuilder:resource:scope=Cluster,categories={crossplane,managed,aws}

func (*Repository) DeepCopy

func (in *Repository) DeepCopy() *Repository

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

func (*Repository) DeepCopyInto

func (in *Repository) DeepCopyInto(out *Repository)

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

func (*Repository) DeepCopyObject

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

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

func (*Repository) GetCondition

func (mg *Repository) GetCondition(ct xpv1.ConditionType) xpv1.Condition

GetCondition of this Repository.

func (*Repository) GetDeletionPolicy

func (mg *Repository) GetDeletionPolicy() xpv1.DeletionPolicy

GetDeletionPolicy of this Repository.

func (*Repository) GetProviderConfigReference

func (mg *Repository) GetProviderConfigReference() *xpv1.Reference

GetProviderConfigReference of this Repository.

func (*Repository) GetProviderReference

func (mg *Repository) GetProviderReference() *xpv1.Reference

GetProviderReference of this Repository. Deprecated: Use GetProviderConfigReference.

func (*Repository) GetWriteConnectionSecretToReference

func (mg *Repository) GetWriteConnectionSecretToReference() *xpv1.SecretReference

GetWriteConnectionSecretToReference of this Repository.

func (*Repository) SetConditions

func (mg *Repository) SetConditions(c ...xpv1.Condition)

SetConditions of this Repository.

func (*Repository) SetDeletionPolicy

func (mg *Repository) SetDeletionPolicy(r xpv1.DeletionPolicy)

SetDeletionPolicy of this Repository.

func (*Repository) SetProviderConfigReference

func (mg *Repository) SetProviderConfigReference(r *xpv1.Reference)

SetProviderConfigReference of this Repository.

func (*Repository) SetProviderReference

func (mg *Repository) SetProviderReference(r *xpv1.Reference)

SetProviderReference of this Repository. Deprecated: Use SetProviderConfigReference.

func (*Repository) SetWriteConnectionSecretToReference

func (mg *Repository) SetWriteConnectionSecretToReference(r *xpv1.SecretReference)

SetWriteConnectionSecretToReference of this Repository.

type RepositoryList

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

RepositoryList contains a list of ECRs

func (*RepositoryList) DeepCopy

func (in *RepositoryList) DeepCopy() *RepositoryList

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

func (*RepositoryList) DeepCopyInto

func (in *RepositoryList) DeepCopyInto(out *RepositoryList)

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

func (*RepositoryList) DeepCopyObject

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

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

func (*RepositoryList) GetItems

func (l *RepositoryList) GetItems() []resource.Managed

GetItems of this RepositoryList.

type RepositoryObservation

type RepositoryObservation struct {
	// The date and time, in JavaScript date format, when the repository was created.
	CreatedAt *metav1.Time `json:"createdAt,omitempty"`

	// The AWS account ID associated with the registry that contains the repository.
	RegistryID string `json:"registryId"`

	// The Amazon Resource Name (ARN) that identifies the repository. The ARN contains
	// the arn:aws:ecr namespace, followed by the region of the repository, AWS
	// account ID of the repository owner, repository namespace, and repository
	// name. For example, arn:aws:ecr:region:012345678910:repository/test.
	RepositoryArn string `json:"repositoryArn,omitempty"`

	// The name of the repository.
	RepositoryName string `json:"repositoryName,omitempty"`

	// The URI for the repository. You can use this URI for container image push
	// and pull operations.
	RepositoryURI string `json:"repositoryUri,omitempty"`
}

RepositoryObservation keeps the state for the external resource

func (*RepositoryObservation) DeepCopy

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

func (*RepositoryObservation) DeepCopyInto

func (in *RepositoryObservation) DeepCopyInto(out *RepositoryObservation)

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

type RepositoryParameters

type RepositoryParameters struct {

	// Region is the region you'd like your Repository to be created in.
	Region string `json:"region"`

	// The image scanning configuration for the repository. This determines whether
	// images are scanned for known vulnerabilities after being pushed to the repository.
	// +optional
	ImageScanningConfiguration *ImageScanningConfiguration `json:"imageScanningConfiguration,omitempty"`

	// The tag mutability setting for the repository. If this parameter is omitted,
	// the default setting of MUTABLE will be used which will allow image tags to
	// be overwritten. If IMMUTABLE is specified, all image tags within the repository
	// will be immutable which will prevent them from being overwritten.
	// +optional
	// +kubebuilder:validation:Enum=MUTABLE;IMMUTABLE
	ImageTagMutability *string `json:"imageTagMutability,omitempty"`

	// Metadata tagging key value pairs
	// +optional
	Tags []Tag `json:"tags,omitempty"`
}

RepositoryParameters define the desired state of an AWS Elastic Container Repository

func (*RepositoryParameters) DeepCopy

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

func (*RepositoryParameters) DeepCopyInto

func (in *RepositoryParameters) DeepCopyInto(out *RepositoryParameters)

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

type RepositorySpec

type RepositorySpec struct {
	xpv1.ResourceSpec `json:",inline"`
	ForProvider       RepositoryParameters `json:"forProvider"`
}

A RepositorySpec defines the desired state of a Elastic Container Repository.

func (*RepositorySpec) DeepCopy

func (in *RepositorySpec) DeepCopy() *RepositorySpec

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

func (*RepositorySpec) DeepCopyInto

func (in *RepositorySpec) DeepCopyInto(out *RepositorySpec)

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

type RepositoryStatus

type RepositoryStatus struct {
	xpv1.ResourceStatus `json:",inline"`
	AtProvider          RepositoryObservation `json:"atProvider"`
}

A RepositoryStatus represents the observed state of a Elastic Container Repository.

func (*RepositoryStatus) DeepCopy

func (in *RepositoryStatus) DeepCopy() *RepositoryStatus

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

func (*RepositoryStatus) DeepCopyInto

func (in *RepositoryStatus) DeepCopyInto(out *RepositoryStatus)

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

type Tag

type Tag struct {

	// Key is the name of the tag.
	Key string `json:"key"`

	// Value is the value of the tag.
	Value string `json:"value"`
}

Tag defines a tag

func BuildFromECRTags

func BuildFromECRTags(tags []ecr.Tag) []Tag

BuildFromECRTags returns a list of tags, off of the given ecr tags

func (*Tag) DeepCopy

func (in *Tag) DeepCopy() *Tag

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

func (*Tag) DeepCopyInto

func (in *Tag) DeepCopyInto(out *Tag)

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

Jump to

Keyboard shortcuts

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