public class DockerSlave extends OneShotSlave
EphemeralNode using docker containers to host the build processes.
 Slave is dedicated to a specific $Job, and even better to a specific build, but when this class
 is created the build does not yet exists due to Jenkins lifecycle.| Modifier and Type | Class and Description | 
|---|---|
| static class  | DockerSlave.DockerSlaveRunListenerThis listener get notified as the build is going to start. | 
| static class  | DockerSlave.DockerSlaveSCMListenerThis listener get notified as the build completes the SCM checkout. | 
hudson.model.Slave.JnlpJar, hudson.model.Slave.SlaveDescriptor| Modifier and Type | Field and Description | 
|---|---|
| static String | SLAVE_ROOT | 
RUN_LISTENER| Constructor and Description | 
|---|
| DockerSlave(String name,
           String nodeDescription,
           String labelString,
           DockerProvisioner provisioner,
           hudson.model.Queue.Item queueItem) | 
| Modifier and Type | Method and Description | 
|---|---|
| DockerSlave | asNode() | 
| DockerComputer | createComputer() | 
| hudson.Launcher | createLauncher(hudson.model.TaskListener listener)Create a custom $ Launcherwhich relies ondocker runto start a new process | 
| DockerComputer | getComputer() | 
| long | getQueueItemId() | 
getNumExecutorsequals, getClockDifferenceCallable, getDescriptor, getLabelString, getLauncher, getMode, getNodeDescription, getNodeName, getNodeProperties, getRemoteFS, getRetentionStrategy, getRootPath, getUserId, getWorkspaceFor, getWorkspaceRoot, hashCode, readResolve, setLabelString, setLauncher, setMode, setNodeName, setRetentionStrategy, setUserId, toStringcanTake, canTake, checkPermission, createPath, getACL, getAssignedLabels, getChannel, getClockDifference, getDisplayName, getFileSystemProvisioner, getLabelCloud, getNodePropertyDescriptors, getSearchUrl, getSelfLabel, hasPermission, isAcceptingTasks, isHoldOffLaunchUntilSave, reconfigure, save, toComputerpublic static final String SLAVE_ROOT
public DockerSlave(String name, String nodeDescription, String labelString, DockerProvisioner provisioner, hudson.model.Queue.Item queueItem) throws hudson.model.Descriptor.FormException, IOException
hudson.model.Descriptor.FormExceptionIOExceptionpublic DockerComputer createComputer()
createComputer in class hudson.model.Slavepublic DockerSlave asNode()
public DockerComputer getComputer()
getComputer in class OneShotSlavepublic long getQueueItemId()
public hudson.Launcher createLauncher(hudson.model.TaskListener listener)
Launcher which relies on docker run to start a new processcreateLauncher in class OneShotSlaveCopyright © 2016–2017. All rights reserved.