Package io.fabric8.openshift.api.model
Class ImageSource
- java.lang.Object
-
- io.fabric8.openshift.api.model.ImageSource
-
- All Implemented Interfaces:
io.fabric8.kubernetes.api.builder.Editable<ImageSourceBuilder>,io.fabric8.kubernetes.api.model.KubernetesResource,Serializable
@Generated("io.fabric8.kubernetes.schema.generator.model.ModelGenerator") public class ImageSource extends Object implements io.fabric8.kubernetes.api.builder.Editable<ImageSourceBuilder>, io.fabric8.kubernetes.api.model.KubernetesResource
ImageSource is used to describe build source that will be extracted from an image or used during a multi stage build. A reference of type ImageStreamTag, ImageStreamImage or DockerImage may be used. A pull secret can be specified to pull the image from an external registry or override the default service account secret if pulling from the internal registry. Image sources can either be used to extract content from an image and place it into the build context along with the repository source, or used directly during a multi-stage container image build to allow content to be copied without overwriting the contents of the repository source (see the 'paths' and 'as' fields).- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ImageSource()No args constructor for use in serializationImageSource(List<String> as, io.fabric8.kubernetes.api.model.ObjectReference from, List<ImageSourcePath> paths, io.fabric8.kubernetes.api.model.LocalObjectReference pullSecret)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ImageSourceBuilderedit()Map<String,Object>getAdditionalProperties()List<String>getAs()A list of image names that this source will be used in place of during a multi-stage container image build.io.fabric8.kubernetes.api.model.ObjectReferencegetFrom()ImageSource is used to describe build source that will be extracted from an image or used during a multi stage build.List<ImageSourcePath>getPaths()paths is a list of source and destination paths to copy from the image.io.fabric8.kubernetes.api.model.LocalObjectReferencegetPullSecret()ImageSource is used to describe build source that will be extracted from an image or used during a multi stage build.voidsetAdditionalProperties(Map<String,Object> additionalProperties)voidsetAdditionalProperty(String name, Object value)voidsetAs(List<String> as)A list of image names that this source will be used in place of during a multi-stage container image build.voidsetFrom(io.fabric8.kubernetes.api.model.ObjectReference from)ImageSource is used to describe build source that will be extracted from an image or used during a multi stage build.voidsetPaths(List<ImageSourcePath> paths)paths is a list of source and destination paths to copy from the image.voidsetPullSecret(io.fabric8.kubernetes.api.model.LocalObjectReference pullSecret)ImageSource is used to describe build source that will be extracted from an image or used during a multi stage build.ImageSourceBuildertoBuilder()
-
-
-
Constructor Detail
-
ImageSource
public ImageSource()
No args constructor for use in serialization
-
ImageSource
public ImageSource(List<String> as, io.fabric8.kubernetes.api.model.ObjectReference from, List<ImageSourcePath> paths, io.fabric8.kubernetes.api.model.LocalObjectReference pullSecret)
-
-
Method Detail
-
getAs
public List<String> getAs()
A list of image names that this source will be used in place of during a multi-stage container image build. For instance, a Dockerfile that uses "COPY --from=nginx:latest" will first check for an image source that has "nginx:latest" in this field before attempting to pull directly. If the Dockerfile does not reference an image source it is ignored. This field and paths may both be set, in which case the contents will be used twice.
-
setAs
public void setAs(List<String> as)
A list of image names that this source will be used in place of during a multi-stage container image build. For instance, a Dockerfile that uses "COPY --from=nginx:latest" will first check for an image source that has "nginx:latest" in this field before attempting to pull directly. If the Dockerfile does not reference an image source it is ignored. This field and paths may both be set, in which case the contents will be used twice.
-
getFrom
public io.fabric8.kubernetes.api.model.ObjectReference getFrom()
ImageSource is used to describe build source that will be extracted from an image or used during a multi stage build. A reference of type ImageStreamTag, ImageStreamImage or DockerImage may be used. A pull secret can be specified to pull the image from an external registry or override the default service account secret if pulling from the internal registry. Image sources can either be used to extract content from an image and place it into the build context along with the repository source, or used directly during a multi-stage container image build to allow content to be copied without overwriting the contents of the repository source (see the 'paths' and 'as' fields).
-
setFrom
public void setFrom(io.fabric8.kubernetes.api.model.ObjectReference from)
ImageSource is used to describe build source that will be extracted from an image or used during a multi stage build. A reference of type ImageStreamTag, ImageStreamImage or DockerImage may be used. A pull secret can be specified to pull the image from an external registry or override the default service account secret if pulling from the internal registry. Image sources can either be used to extract content from an image and place it into the build context along with the repository source, or used directly during a multi-stage container image build to allow content to be copied without overwriting the contents of the repository source (see the 'paths' and 'as' fields).
-
getPaths
public List<ImageSourcePath> getPaths()
paths is a list of source and destination paths to copy from the image. This content will be copied into the build context prior to starting the build. If no paths are set, the build context will not be altered.
-
setPaths
public void setPaths(List<ImageSourcePath> paths)
paths is a list of source and destination paths to copy from the image. This content will be copied into the build context prior to starting the build. If no paths are set, the build context will not be altered.
-
getPullSecret
public io.fabric8.kubernetes.api.model.LocalObjectReference getPullSecret()
ImageSource is used to describe build source that will be extracted from an image or used during a multi stage build. A reference of type ImageStreamTag, ImageStreamImage or DockerImage may be used. A pull secret can be specified to pull the image from an external registry or override the default service account secret if pulling from the internal registry. Image sources can either be used to extract content from an image and place it into the build context along with the repository source, or used directly during a multi-stage container image build to allow content to be copied without overwriting the contents of the repository source (see the 'paths' and 'as' fields).
-
setPullSecret
public void setPullSecret(io.fabric8.kubernetes.api.model.LocalObjectReference pullSecret)
ImageSource is used to describe build source that will be extracted from an image or used during a multi stage build. A reference of type ImageStreamTag, ImageStreamImage or DockerImage may be used. A pull secret can be specified to pull the image from an external registry or override the default service account secret if pulling from the internal registry. Image sources can either be used to extract content from an image and place it into the build context along with the repository source, or used directly during a multi-stage container image build to allow content to be copied without overwriting the contents of the repository source (see the 'paths' and 'as' fields).
-
edit
public ImageSourceBuilder edit()
- Specified by:
editin interfaceio.fabric8.kubernetes.api.builder.Editable<ImageSourceBuilder>
-
toBuilder
public ImageSourceBuilder toBuilder()
-
-