Class DockerBuilderPublisher
java.lang.Object
hudson.tasks.BuildStepCompatibilityLayer
hudson.tasks.Builder
com.nirima.jenkins.plugins.docker.builder.DockerBuilderPublisher
- All Implemented Interfaces:
ExtensionPoint,Describable<Builder>,BuildStep,SimpleBuildStep
Builder extension to build / publish an image from a Dockerfile.
TODO automatic migration to CloudBees Docker Build and Publish
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface hudson.tasks.BuildStep
BuildStep.PublisherListNested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudsonNested classes/interfaces inherited from interface jenkins.tasks.SimpleBuildStep
SimpleBuildStep.LastBuildAction, SimpleBuildStep.LastBuildActionFactory -
Field Summary
FieldsModifier and TypeFieldDescriptionfinal booleanfinal booleanfinal Stringfinal Stringbooleanbooleanfinal booleanDeprecated.Fields inherited from interface hudson.tasks.BuildStep
BUILDERS, PUBLISHERS -
Constructor Summary
ConstructorsConstructorDescriptionDockerBuilderPublisher(String dockerFileDirectory, org.jenkinsci.plugins.docker.commons.credentials.DockerRegistryEndpoint fromRegistry, String cloud, String tagsString, boolean pushOnSuccess, String pushCredentialsId, boolean cleanImages, boolean cleanupWithJenkinsJobDelete) -
Method Summary
Modifier and TypeMethodDescriptionprotected DockerAPIgetDockerAPI(Launcher launcher) org.jenkinsci.plugins.docker.commons.credentials.DockerRegistryEndpointDeprecated.org.jenkinsci.plugins.docker.commons.credentials.DockerRegistryEndpointgetRegistry(com.github.dockerjava.api.model.Identifier identifier) Deprecated.getTags()booleanbooleanisPull()voidperform(Run<?, ?> run, FilePath workspace, Launcher launcher, TaskListener listener) voidsetBuildArgs(Map<String, String> buildArgs) voidsetBuildArgsString(String buildArgsString) voidsetNoCache(boolean noCache) voidsetPull(boolean pull) voidvoidsetTagsString(String tagsString) Methods inherited from class hudson.tasks.Builder
all, getRequiredMonitorService, prebuildMethods inherited from class hudson.tasks.BuildStepCompatibilityLayer
getProjectAction, getProjectAction, getProjectActions, perform, perform, prebuildMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface hudson.tasks.BuildStep
getProjectAction, getProjectActions, getRequiredMonitorService, perform, prebuildMethods inherited from interface jenkins.tasks.SimpleBuildStep
perform, perform, requiresWorkspace
-
Field Details
-
dockerFileDirectory
-
tag
Deprecated.usesetTags(List)and/orgetTags() -
pushOnSuccess
public final boolean pushOnSuccess -
cleanImages
public final boolean cleanImages -
cleanupWithJenkinsJobDelete
public final boolean cleanupWithJenkinsJobDelete -
cloud
-
noCache
public boolean noCache -
pull
public boolean pull
-
-
Constructor Details
-
DockerBuilderPublisher
@DataBoundConstructor public DockerBuilderPublisher(String dockerFileDirectory, @Nullable org.jenkinsci.plugins.docker.commons.credentials.DockerRegistryEndpoint fromRegistry, @Nullable String cloud, @Nullable String tagsString, boolean pushOnSuccess, @Nullable String pushCredentialsId, boolean cleanImages, boolean cleanupWithJenkinsJobDelete)
-
-
Method Details
-
getRegistry
@Deprecated public org.jenkinsci.plugins.docker.commons.credentials.DockerRegistryEndpoint getRegistry(com.github.dockerjava.api.model.Identifier identifier) Deprecated. -
getPullCredentialsId
Deprecated.- Returns:
- old field no longer in use
-
getPushCredentialsId
-
getTags
-
setTags
-
getTagsString
-
setTagsString
-
getBuildArgs
-
setBuildArgs
-
getBuildArgsString
-
setBuildArgsString
-
getFromRegistry
@CheckForNull public org.jenkinsci.plugins.docker.commons.credentials.DockerRegistryEndpoint getFromRegistry() -
isNoCache
public boolean isNoCache() -
setNoCache
@DataBoundSetter public void setNoCache(boolean noCache) -
isPull
public boolean isPull() -
setPull
@DataBoundSetter public void setPull(boolean pull) -
getDockerAPI
-
perform
public void perform(Run<?, ?> run, FilePath workspace, Launcher launcher, TaskListener listener) throws InterruptedException, IOException- Specified by:
performin interfaceSimpleBuildStep- Throws:
InterruptedExceptionIOException
-
getDescriptor
- Specified by:
getDescriptorin interfaceDescribable<Builder>- Overrides:
getDescriptorin classBuilder
-
setTags(List)and/orgetTags()