image

package
v3.9.0-alpha.0 Latest Latest
Warning

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

Go to latest
Published: Dec 1, 2017 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Overview

+groupName=image.openshift.io Package api is the internal version of the API.

Index

Constants

View Source
const (
	// DockerDefaultNamespace is the value for namespace when a single segment name is provided.
	DockerDefaultNamespace = "library"
	// DockerDefaultRegistry is the value for the registry when none was provided.
	DockerDefaultRegistry = "docker.io"
	// DockerDefaultV1Registry is the host name of the default v1 registry
	DockerDefaultV1Registry = "index." + DockerDefaultRegistry
	// DockerDefaultV2Registry is the host name of the default v2 registry
	DockerDefaultV2Registry = "registry-1." + DockerDefaultRegistry

	// TagReferenceAnnotationTagHidden indicates that a given TagReference is hidden from search results
	TagReferenceAnnotationTagHidden = "hidden"

	// ImportRegistryNotAllowed indicates that the image tag was not imported due to
	// untrusted registry.
	ImportRegistryNotAllowed = "registry is not allowed for import"
)
View Source
const (
	GroupName       = "image.openshift.io"
	LegacyGroupName = ""
)
View Source
const (
	// ManagedByOpenShiftAnnotation indicates that an image is managed by OpenShift's registry.
	ManagedByOpenShiftAnnotation = "openshift.io/image.managed"

	// DockerImageRepositoryCheckAnnotation indicates that OpenShift has
	// attempted to import tag and image information from an external Docker
	// image repository.
	DockerImageRepositoryCheckAnnotation = "openshift.io/image.dockerRepositoryCheck"

	// InsecureRepositoryAnnotation may be set true on an image stream to allow insecure access to pull content.
	InsecureRepositoryAnnotation = "openshift.io/image.insecureRepository"

	// ExcludeImageSecretAnnotation indicates that a secret should not be returned by imagestream/secrets.
	ExcludeImageSecretAnnotation = "openshift.io/image.excludeSecret"

	// DockerImageLayersOrderAnnotation describes layers order in the docker image.
	DockerImageLayersOrderAnnotation = "image.openshift.io/dockerLayersOrder"

	// DockerImageLayersOrderAscending indicates that image layers are sorted in
	// the order of their addition (from oldest to latest)
	DockerImageLayersOrderAscending = "ascending"

	// DockerImageLayersOrderDescending indicates that layers are sorted in
	// reversed order of their addition (from newest to oldest).
	DockerImageLayersOrderDescending = "descending"

	// ImporterPreferArchAnnotation represents an architecture that should be
	// selected if an image uses a manifest list and it should be
	// downconverted.
	ImporterPreferArchAnnotation = "importer.image.openshift.io/prefer-arch"

	// ImporterPreferOSAnnotation represents an operation system that should
	// be selected if an image uses a manifest list and it should be
	// downconverted.
	ImporterPreferOSAnnotation = "importer.image.openshift.io/prefer-os"

	// ImageManifestBlobStoredAnnotation indicates that manifest and config blobs of image are stored in on
	// storage of integrated Docker registry.
	ImageManifestBlobStoredAnnotation = "image.openshift.io/manifestBlobStored"

	// DefaultImageTag is used when an image tag is needed and the configuration does not specify a tag to use.
	DefaultImageTag = "latest"

	// ResourceImageStreams represents a number of image streams in a project.
	ResourceImageStreams kapi.ResourceName = "openshift.io/imagestreams"

	// ResourceImageStreamImages represents a number of unique references to images in all image stream
	// statuses of a project.
	ResourceImageStreamImages kapi.ResourceName = "openshift.io/images"

	// ResourceImageStreamTags represents a number of unique references to images in all image stream specs
	// of a project.
	ResourceImageStreamTags kapi.ResourceName = "openshift.io/image-tags"

	// Limit that applies to images. Used with a max["storage"] LimitRangeItem to set
	// the maximum size of an image.
	LimitTypeImage kapi.LimitType = "openshift.io/Image"

	// Limit that applies to image streams. Used with a max[resource] LimitRangeItem to set the maximum number
	// of resource. Where the resource is one of "openshift.io/images" and "openshift.io/image-tags".
	LimitTypeImageStream kapi.LimitType = "openshift.io/ImageStream"
)
View Source
const (
	// SignatureTrusted means the signing key or certificate was valid and the signature matched the image at
	// the probe time.
	SignatureTrusted = "Trusted"
	// SignatureForImage means the signature matches image object containing it.
	SignatureForImage = "ForImage"
	// SignatureExpired means the signature or its signing key or certificate had been expired at the probe
	// time.
	SignatureExpired = "Expired"
	// SignatureRevoked means the signature or its signing key or certificate has been revoked.
	SignatureRevoked = "Revoked"
)

These are valid conditions of an image signature.

View Source
const (
	// The supported type of image signature.
	ImageSignatureTypeAtomicImageV1 string = "AtomicImageV1"
)

Variables

View Source
var (
	SchemeGroupVersion       = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal}
	LegacySchemeGroupVersion = schema.GroupVersion{Group: LegacyGroupName, Version: runtime.APIVersionInternal}

	LegacySchemeBuilder    = runtime.NewSchemeBuilder(addLegacyKnownTypes, RegisterDeepCopies)
	AddToSchemeInCoreGroup = LegacySchemeBuilder.AddToScheme

	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
	AddToScheme   = SchemeBuilder.AddToScheme
)
View Source
var ErrImageStreamImportUnsupported = errors.New("the server does not support directly importing images - create an image stream with tags or the dockerImageRepository field set")

ErrImageStreamImportUnsupported is an error client receive when the import failed.

Functions

func AddTagEventToImageStream

func AddTagEventToImageStream(stream *ImageStream, tag string, next TagEvent) bool

AddTagEventToImageStream attempts to update the given image stream with a tag event. It will collapse duplicate entries - returning true if a change was made or false if no change occurred. Any successful tag resets the status field.

func DifferentTagEvent

func DifferentTagEvent(stream *ImageStream, tag string, next TagEvent) bool

DifferentTagEvent returns true if the supplied tag event matches the current stream tag event. Generation is not compared.

func DifferentTagGeneration

func DifferentTagGeneration(stream *ImageStream, tag string) bool

DifferentTagEvent compares the generation on tag's spec vs its status. Returns if spec generation is newer than status one.

func DigestOrImageMatch added in v3.7.0

func DigestOrImageMatch(image, imageID string) bool

DigestOrImageMatch matches the digest in the image name.

func DockerImageReferenceForImage

func DockerImageReferenceForImage(stream *ImageStream, imageID string) (string, bool)

DockerImageReferenceForImage returns the docker reference for specified image. Assuming the image stream contains the image and the image has corresponding tag, this function will try to find this tag and take the reference policy into the account. If the image stream does not reference the image or the image does not have corresponding tag event, this function will return false.

func HasTagCondition

func HasTagCondition(stream *ImageStream, tag string, condition TagEventCondition) bool

HasTagCondition returns true if the specified image stream tag has a condition with the same type, status, and reason (does not check generation, date, or message).

func ImageStreamSelector added in v3.7.0

func ImageStreamSelector(obj runtime.Object, fieldSet fields.Set) error

func IndexOfImageSignature

func IndexOfImageSignature(signatures []ImageSignature, sType string, sContent []byte) int

IndexOfImageSignature returns index of signature identified by type and blob in the image if present. It returns -1 otherwise.

func IndexOfImageSignatureByName

func IndexOfImageSignatureByName(signatures []ImageSignature, name string) int

IndexOfImageSignatureByName returns an index of signature identified by name in the image if present. It returns -1 otherwise.

func IsKindOrLegacy

func IsKindOrLegacy(kind string, gk schema.GroupKind) bool

IsKindOrLegacy checks if the provided GroupKind matches with the given kind by looking up the API group and also the legacy API.

func IsRegistryDockerHub

func IsRegistryDockerHub(registry string) bool

IsRegistryDockerHub returns true if the given registry name belongs to Docker hub.

func IsResourceOrLegacy

func IsResourceOrLegacy(resource string, gr schema.GroupResource) bool

IsResourceOrLegacy checks if the provided GroupResources matches with the given resource by looking up the API group and also the legacy API.

func JoinImageSignatureName

func JoinImageSignatureName(imageName, signatureName string) (string, error)

JoinImageSignatureName joins image name and custom signature name into one string with @ separator.

func JoinImageStreamImage added in v3.7.0

func JoinImageStreamImage(name, id string) string

JoinImageStreamImage creates a name for image stream image object from an image stream name and an id.

func JoinImageStreamTag

func JoinImageStreamTag(name, tag string) string

JoinImageStreamTag turns a name and tag into the name of an ImageStreamTag

func Kind

func Kind(kind string) schema.GroupKind

Kind takes an unqualified kind and returns back a Group qualified GroupKind

func LabelForStream

func LabelForStream(stream *ImageStream) string

func LatestObservedTagGeneration

func LatestObservedTagGeneration(stream *ImageStream, tag string) int64

LatestObservedTagGeneration returns the generation value for the given tag that has been observed by the controller monitoring the image stream. If the tag has not been observed, the generation is zero.

func LegacyKind

func LegacyKind(kind string) schema.GroupKind

func LegacyResource

func LegacyResource(resource string) schema.GroupResource

func MostAccuratePullSpec

func MostAccuratePullSpec(pullSpec string, id, tag string) (string, bool)

MostAccuratePullSpec returns a docker image reference that uses the current ID if possible, the current tag otherwise, and returns false if the reference if the spec could not be parsed. The returned spec has all client defaults applied.

func NormalizeImageStreamTag

func NormalizeImageStreamTag(name string) string

NormalizeImageStreamTag normalizes an image stream tag by defaulting to 'latest' if no tag has been specified.

func ParseImageStreamImageName

func ParseImageStreamImageName(input string) (name string, id string, err error)

ParseImageStreamImageName splits a string into its name component and ID component, and returns an error if the string is not in the right form.

func ParseImageStreamTagName

func ParseImageStreamTagName(istag string) (name string, tag string, err error)

ParseImageStreamTagName splits a string into its name component and tag component, and returns an error if the string is not in the right form.

func PrioritizeTags

func PrioritizeTags(tags []string)

PrioritizeTags orders a set of image tags with a few conventions:

1. the "latest" tag, if present, should be first 2. any tags that represent a semantic minor version ("5.1", "v5.1", "v5.1-rc1") should be next, in descending order 3. any tags that represent a full semantic version ("5.1.3-other", "v5.1.3-other") should be next, in descending order 4. any remaining tags should be sorted in lexicographic order

The method updates the tags in place.

func RegisterDeepCopies deprecated

func RegisterDeepCopies(scheme *runtime.Scheme) error

RegisterDeepCopies adds deep-copy functions to the given scheme. Public to allow building arbitrary schemes.

Deprecated: deepcopy registration will go away when static deepcopy is fully implemented.

func ResolveLatestTaggedImage

func ResolveLatestTaggedImage(stream *ImageStream, tag string) (string, bool)

ResolveLatestTaggedImage returns the appropriate pull spec for a given tag in the image stream, handling the tag's reference policy if necessary to return a resolved image. Callers that transform an ImageStreamTag into a pull spec should use this method instead of LatestTaggedImage.

func ResolveReferenceForTagEvent

func ResolveReferenceForTagEvent(stream *ImageStream, tag string, latest *TagEvent) string

ResolveReferenceForTagEvent applies the tag reference rules for a stream, tag, and tag event for that tag.

func ResolveTagReference

func ResolveTagReference(stream *ImageStream, tag string, latest *TagEvent) (string, bool)

ResolveTagReference applies the tag reference rules for a stream, tag, and tag event for that tag. It returns true if the tag is

func Resource

func Resource(resource string) schema.GroupResource

Resource takes an unqualified resource and returns back a Group qualified GroupResource

func SetTagConditions

func SetTagConditions(stream *ImageStream, tag string, conditions ...TagEventCondition)

SetTagConditions applies the specified conditions to the status of the given tag.

func ShortDockerImageID

func ShortDockerImageID(image *DockerImage, length int) string

ShortDockerImageID returns a short form of the provided DockerImage ID for display

func SortStatusTags

func SortStatusTags(tags map[string]TagEventList) []string

SortStatusTags sorts the status tags of an image stream based on the latest created

func SplitImageSignatureName

func SplitImageSignatureName(imageSignatureName string) (imageName, signatureName string, err error)

SplitImageSignatureName splits given signature name into image name and signature name.

func SplitImageStreamImage

func SplitImageStreamImage(nameAndID string) (name string, id string, ok bool)

SplitImageStreamImage turns the name of an ImageStreamImage into Name and ID. It returns false if the ID was not properly specified in the name.

func SplitImageStreamTag

func SplitImageStreamTag(nameAndTag string) (name string, tag string, ok bool)

SplitImageStreamTag turns the name of an ImageStreamTag into Name and Tag. It returns false if the tag was not properly specified in the name.

func UpdateChangedTrackingTags

func UpdateChangedTrackingTags(new, old *ImageStream) int

UpdateChangedTrackingTags identifies any tags in the status that have changed and ensures any referenced tracking tags are also updated. It returns the number of updates applied.

func UpdateTrackingTags

func UpdateTrackingTags(stream *ImageStream, updatedTag string, updatedImage TagEvent) int

UpdateTrackingTags sets updatedImage as the most recent TagEvent for all tags in stream.spec.tags that have from.kind = "ImageStreamTag" and the tag in from.name = updatedTag. from.name may be either <tag> or <stream name>:<tag>. For now, only references to tags in the current stream are supported.

For example, if stream.spec.tags[latest].from.name = 2.0, whenever an image is pushed to this stream with the tag 2.0, status.tags[latest].items[0] will also be updated to point at the same image that was just pushed for 2.0.

Returns the number of tags changed.

func ValidateRegistryURL added in v3.6.1

func ValidateRegistryURL(registryURL string) error

ValidateRegistryURL returns error if the given input is not a valid registry URL. The url may be prefixed with http:// or https:// schema. It may not contain any path or query after the host:[port].

Types

type Descriptor

type Descriptor struct {
	// MediaType describe the type of the content. All text based formats are
	// encoded as utf-8.
	MediaType string `json:"mediaType,omitempty"`

	// Size in bytes of content.
	Size int64 `json:"size,omitempty"`

	// Digest uniquely identifies the content. A byte stream can be verified
	// against against this digest.
	Digest string `json:"digest,omitempty"`
}

Descriptor describes targeted content. Used in conjunction with a blob store, a descriptor can be used to fetch, store and target any kind of blob. The struct also describes the wire protocol format. Fields should only be added but never changed.

func (*Descriptor) DeepCopy added in v3.8.0

func (in *Descriptor) DeepCopy() *Descriptor

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

func (*Descriptor) DeepCopyInto added in v3.8.0

func (in *Descriptor) DeepCopyInto(out *Descriptor)

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

type DockerConfig

type DockerConfig struct {
	Hostname        string              `json:"Hostname,omitempty"`
	Domainname      string              `json:"Domainname,omitempty"`
	User            string              `json:"User,omitempty"`
	Memory          int64               `json:"Memory,omitempty"`
	MemorySwap      int64               `json:"MemorySwap,omitempty"`
	CPUShares       int64               `json:"CpuShares,omitempty"`
	CPUSet          string              `json:"Cpuset,omitempty"`
	AttachStdin     bool                `json:"AttachStdin,omitempty"`
	AttachStdout    bool                `json:"AttachStdout,omitempty"`
	AttachStderr    bool                `json:"AttachStderr,omitempty"`
	PortSpecs       []string            `json:"PortSpecs,omitempty"`
	ExposedPorts    map[string]struct{} `json:"ExposedPorts,omitempty"`
	Tty             bool                `json:"Tty,omitempty"`
	OpenStdin       bool                `json:"OpenStdin,omitempty"`
	StdinOnce       bool                `json:"StdinOnce,omitempty"`
	Env             []string            `json:"Env,omitempty"`
	Cmd             []string            `json:"Cmd,omitempty"`
	DNS             []string            `json:"Dns,omitempty"` // For Docker API v1.9 and below only
	Image           string              `json:"Image,omitempty"`
	Volumes         map[string]struct{} `json:"Volumes,omitempty"`
	VolumesFrom     string              `json:"VolumesFrom,omitempty"`
	WorkingDir      string              `json:"WorkingDir,omitempty"`
	Entrypoint      []string            `json:"Entrypoint,omitempty"`
	NetworkDisabled bool                `json:"NetworkDisabled,omitempty"`
	SecurityOpts    []string            `json:"SecurityOpts,omitempty"`
	OnBuild         []string            `json:"OnBuild,omitempty"`
	Labels          map[string]string   `json:"Labels,omitempty"`
}

DockerConfig is the list of configuration options used when creating a container.

func (*DockerConfig) DeepCopy added in v3.8.0

func (in *DockerConfig) DeepCopy() *DockerConfig

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

func (*DockerConfig) DeepCopyInto added in v3.8.0

func (in *DockerConfig) DeepCopyInto(out *DockerConfig)

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

type DockerConfigHistory

type DockerConfigHistory struct {
	Created    metav1.Time `json:"created"`
	Author     string      `json:"author,omitempty"`
	CreatedBy  string      `json:"created_by,omitempty"`
	Comment    string      `json:"comment,omitempty"`
	EmptyLayer bool        `json:"empty_layer,omitempty"`
}

DockerConfigHistory stores build commands that were used to create an image

func (*DockerConfigHistory) DeepCopy added in v3.8.0

func (in *DockerConfigHistory) DeepCopy() *DockerConfigHistory

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

func (*DockerConfigHistory) DeepCopyInto added in v3.8.0

func (in *DockerConfigHistory) DeepCopyInto(out *DockerConfigHistory)

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

type DockerConfigRootFS

type DockerConfigRootFS struct {
	Type    string   `json:"type"`
	DiffIDs []string `json:"diff_ids,omitempty"`
}

DockerConfigRootFS describes images root filesystem

func (*DockerConfigRootFS) DeepCopy added in v3.8.0

func (in *DockerConfigRootFS) DeepCopy() *DockerConfigRootFS

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

func (*DockerConfigRootFS) DeepCopyInto added in v3.8.0

func (in *DockerConfigRootFS) DeepCopyInto(out *DockerConfigRootFS)

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

type DockerFSLayer

type DockerFSLayer struct {
	// DockerBlobSum is the tarsum of the referenced filesystem image layer
	// TODO make this digest.Digest once docker/distribution is in Godeps
	DockerBlobSum string `json:"blobSum"`
}

DockerFSLayer is a container struct for BlobSums defined in an image manifest

func (*DockerFSLayer) DeepCopy added in v3.8.0

func (in *DockerFSLayer) DeepCopy() *DockerFSLayer

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

func (*DockerFSLayer) DeepCopyInto added in v3.8.0

func (in *DockerFSLayer) DeepCopyInto(out *DockerFSLayer)

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

type DockerHistory

type DockerHistory struct {
	// DockerV1Compatibility is the raw v1 compatibility information
	DockerV1Compatibility string `json:"v1Compatibility"`
}

DockerHistory stores unstructured v1 compatibility information

func (*DockerHistory) DeepCopy added in v3.8.0

func (in *DockerHistory) DeepCopy() *DockerHistory

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

func (*DockerHistory) DeepCopyInto added in v3.8.0

func (in *DockerHistory) DeepCopyInto(out *DockerHistory)

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

type DockerImage

type DockerImage struct {
	metav1.TypeMeta `json:",inline"`

	ID              string        `json:"Id"`
	Parent          string        `json:"Parent,omitempty"`
	Comment         string        `json:"Comment,omitempty"`
	Created         metav1.Time   `json:"Created,omitempty"`
	Container       string        `json:"Container,omitempty"`
	ContainerConfig DockerConfig  `json:"ContainerConfig,omitempty"`
	DockerVersion   string        `json:"DockerVersion,omitempty"`
	Author          string        `json:"Author,omitempty"`
	Config          *DockerConfig `json:"Config,omitempty"`
	Architecture    string        `json:"Architecture,omitempty"`
	Size            int64         `json:"Size,omitempty"`
}

DockerImage is the type representing a docker image and its various properties when retrieved from the Docker client API.

func (*DockerImage) DeepCopy added in v3.8.0

func (in *DockerImage) DeepCopy() *DockerImage

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

func (*DockerImage) DeepCopyInto added in v3.8.0

func (in *DockerImage) DeepCopyInto(out *DockerImage)

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

func (*DockerImage) DeepCopyObject added in v3.8.0

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

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

type DockerImageConfig

type DockerImageConfig struct {
	ID              string                `json:"id"`
	Parent          string                `json:"parent,omitempty"`
	Comment         string                `json:"comment,omitempty"`
	Created         metav1.Time           `json:"created"`
	Container       string                `json:"container,omitempty"`
	ContainerConfig DockerConfig          `json:"container_config,omitempty"`
	DockerVersion   string                `json:"docker_version,omitempty"`
	Author          string                `json:"author,omitempty"`
	Config          *DockerConfig         `json:"config,omitempty"`
	Architecture    string                `json:"architecture,omitempty"`
	Size            int64                 `json:"size,omitempty"`
	RootFS          *DockerConfigRootFS   `json:"rootfs,omitempty"`
	History         []DockerConfigHistory `json:"history,omitempty"`
	OSVersion       string                `json:"os.version,omitempty"`
	OSFeatures      []string              `json:"os.features,omitempty"`
}

DockerImageConfig stores the image configuration

func (*DockerImageConfig) DeepCopy added in v3.8.0

func (in *DockerImageConfig) DeepCopy() *DockerImageConfig

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

func (*DockerImageConfig) DeepCopyInto added in v3.8.0

func (in *DockerImageConfig) DeepCopyInto(out *DockerImageConfig)

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

type DockerImageManifest

type DockerImageManifest struct {
	SchemaVersion int    `json:"schemaVersion"`
	MediaType     string `json:"mediaType,omitempty"`

	// schema1
	Name         string          `json:"name"`
	Tag          string          `json:"tag"`
	Architecture string          `json:"architecture"`
	FSLayers     []DockerFSLayer `json:"fsLayers"`
	History      []DockerHistory `json:"history"`

	// schema2
	Layers []Descriptor `json:"layers"`
	Config Descriptor   `json:"config"`
}

DockerImageManifest represents the Docker v2 image format.

func (*DockerImageManifest) DeepCopy added in v3.8.0

func (in *DockerImageManifest) DeepCopy() *DockerImageManifest

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

func (*DockerImageManifest) DeepCopyInto added in v3.8.0

func (in *DockerImageManifest) DeepCopyInto(out *DockerImageManifest)

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

type DockerImageReference

type DockerImageReference struct {
	Registry  string
	Namespace string
	Name      string
	Tag       string
	ID        string
}

DockerImageReference points to a Docker image.

func DockerImageReferenceForStream

func DockerImageReferenceForStream(stream *ImageStream) (DockerImageReference, error)

DockerImageReferenceForStream returns a DockerImageReference that represents the ImageStream or false, if no valid reference exists.

func ParseDockerImageReference

func ParseDockerImageReference(spec string) (DockerImageReference, error)

ParseDockerImageReference parses a Docker pull spec string into a DockerImageReference.

func (DockerImageReference) AsRepository

func (r DockerImageReference) AsRepository() DockerImageReference

AsRepository returns the reference without tags or IDs.

func (DockerImageReference) AsV2

func (DockerImageReference) DaemonMinimal

func (r DockerImageReference) DaemonMinimal() DockerImageReference

DaemonMinimal clears defaults that Docker assumes.

func (*DockerImageReference) DeepCopy added in v3.8.0

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

func (*DockerImageReference) DeepCopyInto added in v3.8.0

func (in *DockerImageReference) DeepCopyInto(out *DockerImageReference)

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

func (DockerImageReference) DockerClientDefaults

func (r DockerImageReference) DockerClientDefaults() DockerImageReference

DockerClientDefaults sets the default values used by the Docker client.

func (DockerImageReference) Equal

Equal returns true if the other DockerImageReference is equivalent to the reference r. The comparison applies defaults to the Docker image reference, so that e.g., "foobar" equals "docker.io/library/foobar:latest".

func (DockerImageReference) Exact

func (r DockerImageReference) Exact() string

Exact returns a string representation of the set fields on the DockerImageReference

func (DockerImageReference) Minimal

Minimal reduces a DockerImageReference to its minimalist form.

func (DockerImageReference) MostSpecific

func (r DockerImageReference) MostSpecific() DockerImageReference

MostSpecific returns the most specific image reference that can be constructed from the current ref, preferring an ID over a Tag. Allows client code dealing with both tags and IDs to get the most specific reference easily.

func (DockerImageReference) NameString

func (r DockerImageReference) NameString() string

NameString returns the name of the reference with its tag or ID.

func (DockerImageReference) RegistryHostPort

func (r DockerImageReference) RegistryHostPort(insecure bool) (string, string)

RegistryHostPort returns the registry hostname and the port. If the port is not specified in the registry hostname we default to 443. This will also default to Docker client defaults if the registry hostname is empty.

func (DockerImageReference) RegistryURL

func (r DockerImageReference) RegistryURL() *url.URL

RepositoryName returns the registry relative name

func (DockerImageReference) RepositoryName

func (r DockerImageReference) RepositoryName() string

RepositoryName returns the registry relative name

func (DockerImageReference) String

func (r DockerImageReference) String() string

String converts a DockerImageReference to a Docker pull spec (which implies a default namespace according to V1 Docker registry rules). Use Exact() if you want no defaulting.

type DockerV1CompatibilityImage

type DockerV1CompatibilityImage struct {
	ID              string        `json:"id"`
	Parent          string        `json:"parent,omitempty"`
	Comment         string        `json:"comment,omitempty"`
	Created         metav1.Time   `json:"created"`
	Container       string        `json:"container,omitempty"`
	ContainerConfig DockerConfig  `json:"container_config,omitempty"`
	DockerVersion   string        `json:"docker_version,omitempty"`
	Author          string        `json:"author,omitempty"`
	Config          *DockerConfig `json:"config,omitempty"`
	Architecture    string        `json:"architecture,omitempty"`
	Size            int64         `json:"size,omitempty"`
}

DockerV1CompatibilityImage represents the structured v1 compatibility information.

func (*DockerV1CompatibilityImage) DeepCopy added in v3.8.0

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

func (*DockerV1CompatibilityImage) DeepCopyInto added in v3.8.0

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

type DockerV1CompatibilityImageSize

type DockerV1CompatibilityImageSize struct {
	Size int64 `json:"size,omitempty"`
}

DockerV1CompatibilityImageSize represents the structured v1 compatibility information for size

func (*DockerV1CompatibilityImageSize) DeepCopy added in v3.8.0

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

func (*DockerV1CompatibilityImageSize) DeepCopyInto added in v3.8.0

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

type Image

type Image struct {
	metav1.TypeMeta
	metav1.ObjectMeta

	// The string that can be used to pull this image.
	DockerImageReference string
	// Metadata about this image
	DockerImageMetadata DockerImage
	// This attribute conveys the version of docker metadata the JSON should be stored in, which if empty defaults to "1.0"
	DockerImageMetadataVersion string
	// The raw JSON of the manifest
	DockerImageManifest string
	// DockerImageLayers represents the layers in the image. May not be set if the image does not define that data.
	DockerImageLayers []ImageLayer
	// Signatures holds all signatures of the image.
	Signatures []ImageSignature
	// DockerImageSignatures provides the signatures as opaque blobs. This is a part of manifest schema v1.
	DockerImageSignatures [][]byte
	// DockerImageManifestMediaType specifies the mediaType of manifest. This is a part of manifest schema v2.
	DockerImageManifestMediaType string
	// DockerImageConfig is a JSON blob that the runtime uses to set up the container. This is a part of manifest schema v2.
	DockerImageConfig string
}

Image is an immutable representation of a Docker image and metadata at a point in time.

func (*Image) DeepCopy added in v3.8.0

func (in *Image) DeepCopy() *Image

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

func (*Image) DeepCopyInto added in v3.8.0

func (in *Image) DeepCopyInto(out *Image)

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

func (*Image) DeepCopyObject added in v3.8.0

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

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

type ImageImportSpec

type ImageImportSpec struct {
	From kapi.ObjectReference
	To   *kapi.LocalObjectReference

	ImportPolicy    TagImportPolicy
	ReferencePolicy TagReferencePolicy
	IncludeManifest bool
}

ImageImportSpec defines how an image is imported.

func (*ImageImportSpec) DeepCopy added in v3.8.0

func (in *ImageImportSpec) DeepCopy() *ImageImportSpec

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

func (*ImageImportSpec) DeepCopyInto added in v3.8.0

func (in *ImageImportSpec) DeepCopyInto(out *ImageImportSpec)

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

type ImageImportStatus

type ImageImportStatus struct {
	Tag    string
	Status metav1.Status
	Image  *Image
}

ImageImportStatus describes the result of an image import.

func (*ImageImportStatus) DeepCopy added in v3.8.0

func (in *ImageImportStatus) DeepCopy() *ImageImportStatus

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

func (*ImageImportStatus) DeepCopyInto added in v3.8.0

func (in *ImageImportStatus) DeepCopyInto(out *ImageImportStatus)

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

type ImageLayer

type ImageLayer struct {
	// Name of the layer as defined by the underlying store.
	Name string
	// LayerSize of the layer as defined by the underlying store.
	LayerSize int64
	// MediaType of the referenced object.
	MediaType string
}

ImageLayer represents a single layer of the image. Some images may have multiple layers. Some may have none.

func (*ImageLayer) DeepCopy added in v3.8.0

func (in *ImageLayer) DeepCopy() *ImageLayer

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

func (*ImageLayer) DeepCopyInto added in v3.8.0

func (in *ImageLayer) DeepCopyInto(out *ImageLayer)

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

type ImageList

type ImageList struct {
	metav1.TypeMeta
	metav1.ListMeta

	Items []Image
}

ImageList is a list of Image objects.

func (*ImageList) DeepCopy added in v3.8.0

func (in *ImageList) DeepCopy() *ImageList

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

func (*ImageList) DeepCopyInto added in v3.8.0

func (in *ImageList) DeepCopyInto(out *ImageList)

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

func (*ImageList) DeepCopyObject added in v3.8.0

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

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

type ImageLookupPolicy

type ImageLookupPolicy struct {
	// local will change the docker short image references (like "mysql" or
	// "php:latest") on objects in this namespace to the image ID whenever they match
	// this image stream, instead of reaching out to a remote registry. The name will
	// be fully qualified to an image ID if found. The tag's referencePolicy is taken
	// into account on the replaced value. Only works within the current namespace.
	Local bool
}

ImageLookupPolicy describes how an image stream can be used to override the image references used by pods, builds, and other resources in a namespace.

func (*ImageLookupPolicy) DeepCopy added in v3.8.0

func (in *ImageLookupPolicy) DeepCopy() *ImageLookupPolicy

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

func (*ImageLookupPolicy) DeepCopyInto added in v3.8.0

func (in *ImageLookupPolicy) DeepCopyInto(out *ImageLookupPolicy)

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

type ImageSignature

type ImageSignature struct {
	metav1.TypeMeta
	metav1.ObjectMeta

	// Required: Describes a type of stored blob.
	Type string
	// Required: An opaque binary string which is an image's signature.
	Content []byte
	// Conditions represent the latest available observations of a signature's current state.
	Conditions []SignatureCondition

	// A human readable string representing image's identity. It could be a product name and version, or an
	// image pull spec (e.g. "registry.access.redhat.com/rhel7/rhel:7.2").
	ImageIdentity string
	// Contains claims from the signature.
	SignedClaims map[string]string
	// If specified, it is the time of signature's creation.
	Created *metav1.Time
	// If specified, it holds information about an issuer of signing certificate or key (a person or entity
	// who signed the signing certificate or key).
	IssuedBy *SignatureIssuer
	// If specified, it holds information about a subject of signing certificate or key (a person or entity
	// who signed the image).
	IssuedTo *SignatureSubject
}

ImageSignature holds a signature of an image. It allows to verify image identity and possibly other claims as long as the signature is trusted. Based on this information it is possible to restrict runnable images to those matching cluster-wide policy. Mandatory fields should be parsed by clients doing image verification. The others are parsed from signature's content by the server. They serve just an informative purpose.

func (*ImageSignature) DeepCopy added in v3.8.0

func (in *ImageSignature) DeepCopy() *ImageSignature

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

func (*ImageSignature) DeepCopyInto added in v3.8.0

func (in *ImageSignature) DeepCopyInto(out *ImageSignature)

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

func (*ImageSignature) DeepCopyObject added in v3.8.0

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

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

type ImageStream

type ImageStream struct {
	metav1.TypeMeta
	metav1.ObjectMeta

	// Spec describes the desired state of this stream
	Spec ImageStreamSpec
	// Status describes the current state of this stream
	Status ImageStreamStatus
}

ImageStream stores a mapping of tags to images, metadata overrides that are applied when images are tagged in a stream, and an optional reference to a Docker image repository on a registry.

func (*ImageStream) DeepCopy added in v3.8.0

func (in *ImageStream) DeepCopy() *ImageStream

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

func (*ImageStream) DeepCopyInto added in v3.8.0

func (in *ImageStream) DeepCopyInto(out *ImageStream)

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

func (*ImageStream) DeepCopyObject added in v3.8.0

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

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

type ImageStreamImage

type ImageStreamImage struct {
	metav1.TypeMeta
	metav1.ObjectMeta

	// The Image associated with the ImageStream and image name.
	Image Image
}

ImageStreamImage represents an Image that is retrieved by image name from an ImageStream.

func (*ImageStreamImage) DeepCopy added in v3.8.0

func (in *ImageStreamImage) DeepCopy() *ImageStreamImage

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

func (*ImageStreamImage) DeepCopyInto added in v3.8.0

func (in *ImageStreamImage) DeepCopyInto(out *ImageStreamImage)

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

func (*ImageStreamImage) DeepCopyObject added in v3.8.0

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

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

type ImageStreamImport

type ImageStreamImport struct {
	metav1.TypeMeta
	// ObjectMeta must identify the name of the image stream to create or update. If resourceVersion
	// or UID are set, they must match the image stream that will be loaded from the server.
	metav1.ObjectMeta

	// Spec is the set of items desired to be imported
	Spec ImageStreamImportSpec
	// Status is the result of the import
	Status ImageStreamImportStatus
}

ImageStreamImport allows a caller to request information about a set of images for possible import into an image stream, or actually tag the images into the image stream.

func (*ImageStreamImport) DeepCopy added in v3.8.0

func (in *ImageStreamImport) DeepCopy() *ImageStreamImport

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

func (*ImageStreamImport) DeepCopyInto added in v3.8.0

func (in *ImageStreamImport) DeepCopyInto(out *ImageStreamImport)

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

func (*ImageStreamImport) DeepCopyObject added in v3.8.0

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

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

type ImageStreamImportSpec

type ImageStreamImportSpec struct {
	// Import indicates whether to perform an import - if so, the specified tags are set on the spec
	// and status of the image stream defined by the type meta.
	Import bool
	// Repository is an optional import of an entire Docker image repository. A maximum limit on the
	// number of tags imported this way is imposed by the server.
	Repository *RepositoryImportSpec
	// Images are a list of individual images to import.
	Images []ImageImportSpec
}

ImageStreamImportSpec defines what images should be imported.

func (*ImageStreamImportSpec) DeepCopy added in v3.8.0

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

func (*ImageStreamImportSpec) DeepCopyInto added in v3.8.0

func (in *ImageStreamImportSpec) DeepCopyInto(out *ImageStreamImportSpec)

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

type ImageStreamImportStatus

type ImageStreamImportStatus struct {
	// Import is the image stream that was successfully updated or created when 'to' was set.
	Import *ImageStream
	// Repository is set if spec.repository was set to the outcome of the import
	Repository *RepositoryImportStatus
	// Images is set with the result of importing spec.images
	Images []ImageImportStatus
}

ImageStreamImportStatus contains information about the status of an image stream import.

func (*ImageStreamImportStatus) DeepCopy added in v3.8.0

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

func (*ImageStreamImportStatus) DeepCopyInto added in v3.8.0

func (in *ImageStreamImportStatus) DeepCopyInto(out *ImageStreamImportStatus)

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

type ImageStreamList

type ImageStreamList struct {
	metav1.TypeMeta
	metav1.ListMeta

	Items []ImageStream
}

ImageStreamList is a list of ImageStream objects.

func (*ImageStreamList) DeepCopy added in v3.8.0

func (in *ImageStreamList) DeepCopy() *ImageStreamList

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

func (*ImageStreamList) DeepCopyInto added in v3.8.0

func (in *ImageStreamList) DeepCopyInto(out *ImageStreamList)

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

func (*ImageStreamList) DeepCopyObject added in v3.8.0

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

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

type ImageStreamMapping

type ImageStreamMapping struct {
	metav1.TypeMeta
	metav1.ObjectMeta

	// The Docker image repository the specified image is located in
	// DEPRECATED: remove once v1beta1 support is dropped
	// +k8s:conversion-gen=false
	DockerImageRepository string
	// A Docker image.
	Image Image
	// A string value this image can be located with inside the repository.
	Tag string
}

ImageStreamMapping represents a mapping from a single tag to a Docker image as well as the reference to the Docker image repository the image came from.

func (*ImageStreamMapping) DeepCopy added in v3.8.0

func (in *ImageStreamMapping) DeepCopy() *ImageStreamMapping

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

func (*ImageStreamMapping) DeepCopyInto added in v3.8.0

func (in *ImageStreamMapping) DeepCopyInto(out *ImageStreamMapping)

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

func (*ImageStreamMapping) DeepCopyObject added in v3.8.0

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

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

type ImageStreamSpec

type ImageStreamSpec struct {
	// lookupPolicy controls how other resources reference images within this namespace.
	LookupPolicy ImageLookupPolicy
	// Optional, if specified this stream is backed by a Docker repository on this server
	// Deprecated: This field is deprecated as of v3.7 and will be removed in a future release.
	// Specify the source for the tags to be imported in each tag via the spec.tags.from reference instead.
	DockerImageRepository string
	// Tags map arbitrary string values to specific image locators
	Tags map[string]TagReference
}

ImageStreamSpec represents options for ImageStreams.

func (*ImageStreamSpec) DeepCopy added in v3.8.0

func (in *ImageStreamSpec) DeepCopy() *ImageStreamSpec

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

func (*ImageStreamSpec) DeepCopyInto added in v3.8.0

func (in *ImageStreamSpec) DeepCopyInto(out *ImageStreamSpec)

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

type ImageStreamStatus

type ImageStreamStatus struct {
	// DockerImageRepository represents the effective location this stream may be accessed at. May be empty until the server
	// determines where the repository is located
	DockerImageRepository string
	// PublicDockerImageRepository represents the public location from where the image can
	// be pulled outside the cluster. This field may be empty if the administrator
	// has not exposed the integrated registry externally.
	PublicDockerImageRepository string
	// A historical record of images associated with each tag. The first entry in the TagEvent array is
	// the currently tagged image.
	Tags map[string]TagEventList
}

ImageStreamStatus contains information about the state of this image stream.

func (*ImageStreamStatus) DeepCopy added in v3.8.0

func (in *ImageStreamStatus) DeepCopy() *ImageStreamStatus

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

func (*ImageStreamStatus) DeepCopyInto added in v3.8.0

func (in *ImageStreamStatus) DeepCopyInto(out *ImageStreamStatus)

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

type ImageStreamTag

type ImageStreamTag struct {
	metav1.TypeMeta
	metav1.ObjectMeta

	// Tag is the spec tag associated with this image stream tag, and it may be null
	// if only pushes have occurred to this image stream.
	Tag *TagReference

	// Generation is the current generation of the tagged image - if tag is provided
	// and this value is not equal to the tag generation, a user has requested an
	// import that has not completed, or Conditions will be filled out indicating any
	// error.
	Generation int64

	// Conditions is an array of conditions that apply to the image stream tag.
	Conditions []TagEventCondition

	// LookupPolicy indicates whether this tag will handle image references in this
	// namespace.
	LookupPolicy ImageLookupPolicy

	// The Image associated with the ImageStream and tag.
	Image Image
}

ImageStreamTag has a .Name in the format <stream name>:<tag>.

func (*ImageStreamTag) DeepCopy added in v3.8.0

func (in *ImageStreamTag) DeepCopy() *ImageStreamTag

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

func (*ImageStreamTag) DeepCopyInto added in v3.8.0

func (in *ImageStreamTag) DeepCopyInto(out *ImageStreamTag)

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

func (*ImageStreamTag) DeepCopyObject added in v3.8.0

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

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

type ImageStreamTagList

type ImageStreamTagList struct {
	metav1.TypeMeta
	metav1.ListMeta

	Items []ImageStreamTag
}

ImageStreamTagList is a list of ImageStreamTag objects.

func (*ImageStreamTagList) DeepCopy added in v3.8.0

func (in *ImageStreamTagList) DeepCopy() *ImageStreamTagList

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

func (*ImageStreamTagList) DeepCopyInto added in v3.8.0

func (in *ImageStreamTagList) DeepCopyInto(out *ImageStreamTagList)

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

func (*ImageStreamTagList) DeepCopyObject added in v3.8.0

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

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

type RegistryHostnameRetriever added in v3.7.0

type RegistryHostnameRetriever interface {
	InternalRegistryHostname() (string, bool)
	ExternalRegistryHostname() (string, bool)
}

RegistryHostnameRetriever represents an interface for retrieving the hostname of internal and external registry.

func DefaultRegistryHostnameRetriever added in v3.7.0

func DefaultRegistryHostnameRetriever(deprecatedDefaultRegistryEnvFn func() (string, bool), external, internal string) RegistryHostnameRetriever

DefaultRegistryHostnameRetriever is a default implementation of RegistryHostnameRetriever. The first argument is a function that lazy-loads the value of OPENSHIFT_DEFAULT_REGISTRY environment variable which should be deprecated in future.

type RepositoryImportSpec

type RepositoryImportSpec struct {
	// The source of the import, only kind DockerImage is supported
	From kapi.ObjectReference

	ImportPolicy    TagImportPolicy
	ReferencePolicy TagReferencePolicy
	IncludeManifest bool
}

RepositoryImportSpec indicates to load a set of tags from a given Docker image repository

func (*RepositoryImportSpec) DeepCopy added in v3.8.0

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

func (*RepositoryImportSpec) DeepCopyInto added in v3.8.0

func (in *RepositoryImportSpec) DeepCopyInto(out *RepositoryImportSpec)

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

type RepositoryImportStatus

type RepositoryImportStatus struct {
	// Status reflects whether any failure occurred during import
	Status metav1.Status
	// Images is the list of imported images
	Images []ImageImportStatus
	// AdditionalTags are tags that exist in the repository but were not imported because
	// a maximum limit of automatic imports was applied.
	AdditionalTags []string
}

RepositoryImportStatus describes the outcome of the repository import

func (*RepositoryImportStatus) DeepCopy added in v3.8.0

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

func (*RepositoryImportStatus) DeepCopyInto added in v3.8.0

func (in *RepositoryImportStatus) DeepCopyInto(out *RepositoryImportStatus)

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

type SignatureCondition

type SignatureCondition struct {
	// Type of signature condition, Complete or Failed.
	Type SignatureConditionType
	// Status of the condition, one of True, False, Unknown.
	Status kapi.ConditionStatus
	// Last time the condition was checked.
	LastProbeTime metav1.Time
	// Last time the condition transit from one status to another.
	LastTransitionTime metav1.Time
	// (brief) reason for the condition's last transition.
	Reason string
	// Human readable message indicating details about last transition.
	Message string
}

SignatureCondition describes an image signature condition of particular kind at particular probe time.

func (*SignatureCondition) DeepCopy added in v3.8.0

func (in *SignatureCondition) DeepCopy() *SignatureCondition

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

func (*SignatureCondition) DeepCopyInto added in v3.8.0

func (in *SignatureCondition) DeepCopyInto(out *SignatureCondition)

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

type SignatureConditionType

type SignatureConditionType string

SignatureConditionType is a type of image signature condition.

func (*SignatureConditionType) DeepCopy added in v3.8.0

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

func (*SignatureConditionType) DeepCopyInto added in v3.8.0

func (in *SignatureConditionType) DeepCopyInto(out *SignatureConditionType)

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

type SignatureGenericEntity

type SignatureGenericEntity struct {
	// Organization name.
	Organization string
	// Common name (e.g. openshift-signing-service).
	CommonName string
}

SignatureGenericEntity holds a generic information about a person or entity who is an issuer or a subject of signing certificate or key.

func (*SignatureGenericEntity) DeepCopy added in v3.8.0

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

func (*SignatureGenericEntity) DeepCopyInto added in v3.8.0

func (in *SignatureGenericEntity) DeepCopyInto(out *SignatureGenericEntity)

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

type SignatureIssuer

type SignatureIssuer struct {
	SignatureGenericEntity
}

SignatureIssuer holds information about an issuer of signing certificate or key.

func (*SignatureIssuer) DeepCopy added in v3.8.0

func (in *SignatureIssuer) DeepCopy() *SignatureIssuer

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

func (*SignatureIssuer) DeepCopyInto added in v3.8.0

func (in *SignatureIssuer) DeepCopyInto(out *SignatureIssuer)

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

type SignatureSubject

type SignatureSubject struct {
	SignatureGenericEntity
	// If present, it is a human readable key id of public key belonging to the subject used to verify image
	// signature. It should contain at least 64 lowest bits of public key's fingerprint (e.g.
	// 0x685ebe62bf278440).
	PublicKeyID string
}

SignatureSubject holds information about a person or entity who created the signature.

func (*SignatureSubject) DeepCopy added in v3.8.0

func (in *SignatureSubject) DeepCopy() *SignatureSubject

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

func (*SignatureSubject) DeepCopyInto added in v3.8.0

func (in *SignatureSubject) DeepCopyInto(out *SignatureSubject)

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

type TagEvent

type TagEvent struct {
	// When the TagEvent was created
	Created metav1.Time
	// The string that can be used to pull this image
	DockerImageReference string
	// The image
	Image string
	// Generation is the spec tag generation that resulted in this tag being updated
	Generation int64
}

TagEvent is used by ImageRepositoryStatus to keep a historical record of images associated with a tag.

func LatestImageTagEvent

func LatestImageTagEvent(stream *ImageStream, imageID string) (string, *TagEvent)

LatestImageTagEvent returns the most recent TagEvent and the tag for the specified image.

func LatestTaggedImage

func LatestTaggedImage(stream *ImageStream, tag string) *TagEvent

LatestTaggedImage returns the most recent TagEvent for the specified image repository and tag. Will resolve lookups for the empty tag. Returns nil if tag isn't present in stream.status.tags.

func ResolveImageID

func ResolveImageID(stream *ImageStream, imageID string) (*TagEvent, error)

ResolveImageID returns latest TagEvent for specified imageID and an error if there's more than one image matching the ID or when one does not exist.

func (*TagEvent) DeepCopy added in v3.8.0

func (in *TagEvent) DeepCopy() *TagEvent

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

func (*TagEvent) DeepCopyInto added in v3.8.0

func (in *TagEvent) DeepCopyInto(out *TagEvent)

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

type TagEventCondition

type TagEventCondition struct {
	// Type of tag event condition, currently only ImportSuccess
	Type TagEventConditionType
	// Status of the condition, one of True, False, Unknown.
	Status kapi.ConditionStatus
	// LastTransitionTIme is the time the condition transitioned from one status to another.
	LastTransitionTime metav1.Time
	// Reason is a brief machine readable explanation for the condition's last transition.
	Reason string
	// Message is a human readable description of the details about last transition, complementing reason.
	Message string
	// Generation is the spec tag generation that this status corresponds to. If this value is
	// older than the spec tag generation, the user has requested this status tag be updated.
	// This value is set to zero for older versions of streams, which means that no generation
	// was recorded.
	Generation int64
}

TagEventCondition contains condition information for a tag event.

func (*TagEventCondition) DeepCopy added in v3.8.0

func (in *TagEventCondition) DeepCopy() *TagEventCondition

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

func (*TagEventCondition) DeepCopyInto added in v3.8.0

func (in *TagEventCondition) DeepCopyInto(out *TagEventCondition)

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

type TagEventConditionType

type TagEventConditionType string
const (
	// ImportSuccess with status False means the import of the specific tag failed
	ImportSuccess TagEventConditionType = "ImportSuccess"
)

These are valid conditions of TagEvents.

func (*TagEventConditionType) DeepCopy added in v3.8.0

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

func (*TagEventConditionType) DeepCopyInto added in v3.8.0

func (in *TagEventConditionType) DeepCopyInto(out *TagEventConditionType)

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

type TagEventList

type TagEventList struct {
	Items []TagEvent
	// Conditions is an array of conditions that apply to the tag event list.
	Conditions []TagEventCondition
}

TagEventList contains a historical record of images associated with a tag.

func (*TagEventList) DeepCopy added in v3.8.0

func (in *TagEventList) DeepCopy() *TagEventList

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

func (*TagEventList) DeepCopyInto added in v3.8.0

func (in *TagEventList) DeepCopyInto(out *TagEventList)

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

type TagImportPolicy

type TagImportPolicy struct {
	// Insecure is true if the server may bypass certificate verification or connect directly over HTTP during image import.
	Insecure bool
	// Scheduled indicates to the server that this tag should be periodically checked to ensure it is up to date, and imported
	Scheduled bool
}

func (*TagImportPolicy) DeepCopy added in v3.8.0

func (in *TagImportPolicy) DeepCopy() *TagImportPolicy

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

func (*TagImportPolicy) DeepCopyInto added in v3.8.0

func (in *TagImportPolicy) DeepCopyInto(out *TagImportPolicy)

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

type TagReference

type TagReference struct {
	// Name of the tag
	Name string
	// Optional; if specified, annotations that are applied to images retrieved via ImageStreamTags.
	Annotations map[string]string
	// Optional; if specified, a reference to another image that this tag should point to. Valid values
	// are ImageStreamTag, ImageStreamImage, and DockerImage.
	From *kapi.ObjectReference
	// Reference states if the tag will be imported. Default value is false, which means the tag will
	// be imported.
	Reference bool
	// Generation is a counter that tracks mutations to the spec tag (user intent). When a tag reference
	// is changed the generation is set to match the current stream generation (which is incremented every
	// time spec is changed). Other processes in the system like the image importer observe that the
	// generation of spec tag is newer than the generation recorded in the status and use that as a trigger
	// to import the newest remote tag. To trigger a new import, clients may set this value to zero which
	// will reset the generation to the latest stream generation. Legacy clients will send this value as
	// nil which will be merged with the current tag generation.
	Generation *int64
	// ImportPolicy is information that controls how images may be imported by the server.
	ImportPolicy TagImportPolicy
	// ReferencePolicy defines how other components should consume the image.
	ReferencePolicy TagReferencePolicy
}

TagReference specifies optional annotations for images using this tag and an optional reference to an ImageStreamTag, ImageStreamImage, or DockerImage this tag should track.

func FollowTagReference

func FollowTagReference(stream *ImageStream, tag string) (finalTag string, ref *TagReference, ok bool, multiple bool)

FollowTagReference walks through the defined tags on a stream, following any referential tags in the stream. Will return ok if the tag is valid, multiple if the tag had at least reference, and ref and finalTag will be the last tag seen. If a circular loop is found ok will be false.

func (*TagReference) DeepCopy added in v3.8.0

func (in *TagReference) DeepCopy() *TagReference

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

func (*TagReference) DeepCopyInto added in v3.8.0

func (in *TagReference) DeepCopyInto(out *TagReference)

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

func (TagReference) HasAnnotationTag

func (tagref TagReference) HasAnnotationTag(searchTag string) bool

type TagReferencePolicy

type TagReferencePolicy struct {
	// Type determines how the image pull spec should be transformed when the image stream tag is used in
	// deployment config triggers or new builds. The default value is `Source`, indicating the original
	// location of the image should be used (if imported). The user may also specify `Local`, indicating
	// that the pull spec should point to the integrated Docker registry and leverage the registry's
	// ability to proxy the pull to an upstream registry. `Local` allows the credentials used to pull this
	// image to be managed from the image stream's namespace, so others on the platform can access a remote
	// image but have no access to the remote secret. It also allows the image layers to be mirrored into
	// the local registry which the images can still be pulled even if the upstream registry is unavailable.
	Type TagReferencePolicyType
}

TagReferencePolicy describes how pull-specs for images in this image stream tag are generated when image change triggers in deployment configs or builds are resolved. This allows the image stream author to control how images are accessed.

func (*TagReferencePolicy) DeepCopy added in v3.8.0

func (in *TagReferencePolicy) DeepCopy() *TagReferencePolicy

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

func (*TagReferencePolicy) DeepCopyInto added in v3.8.0

func (in *TagReferencePolicy) DeepCopyInto(out *TagReferencePolicy)

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

type TagReferencePolicyType

type TagReferencePolicyType string

TagReferencePolicyType describes how pull-specs for images in an image stream tag are generated when image change triggers are fired.

const (
	// SourceTagReferencePolicy indicates the image's original location should be used when the image stream tag
	// is resolved into other resources (builds and deployment configurations).
	SourceTagReferencePolicy TagReferencePolicyType = "Source"
	// LocalTagReferencePolicy indicates the image should prefer to pull via the local integrated registry,
	// falling back to the remote location if the integrated registry has not been configured. The reference will
	// use the internal DNS name or registry service IP.
	LocalTagReferencePolicy TagReferencePolicyType = "Local"
)

func (*TagReferencePolicyType) DeepCopy added in v3.8.0

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

func (*TagReferencePolicyType) DeepCopyInto added in v3.8.0

func (in *TagReferencePolicyType) DeepCopyInto(out *TagReferencePolicyType)

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

Directories

Path Synopsis
Package docker10 is the docker10 version of the API.
Package docker10 is the docker10 version of the API.
Package dockerpre012 is the dockerpre012 version of the API.
Package dockerpre012 is the dockerpre012 version of the API.
internal
digest
digest is a copy from "github.com/docker/distribution/digest" that is kept because we want to avoid the godep, this package has no non-standard dependencies, and if it changes lots of other docker registry stuff breaks.
digest is a copy from "github.com/docker/distribution/digest" that is kept because we want to avoid the godep, this package has no non-standard dependencies, and if it changes lots of other docker registry stuff breaks.
reference
reference is a copy from "github.com/docker/distribution/reference" that is kept because we want to avoid the godep, this package has no non-standard dependencies, and if it changes lots of other docker registry stuff breaks.
reference is a copy from "github.com/docker/distribution/reference" that is kept because we want to avoid the godep, this package has no non-standard dependencies, and if it changes lots of other docker registry stuff breaks.
v1
+groupName=image.openshift.io Package v1 is the v1 version of the API.
+groupName=image.openshift.io Package v1 is the v1 version of the API.

Jump to

Keyboard shortcuts

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