Package jenkins.plugins.jclouds.compute
Class JCloudsSlaveTemplate
- java.lang.Object
-
- jenkins.plugins.jclouds.compute.JCloudsSlaveTemplate
-
- All Implemented Interfaces:
com.google.common.base.Supplier<JCloudsNodeMetadata>
,Describable<JCloudsSlaveTemplate>
,Supplier<JCloudsNodeMetadata>
public class JCloudsSlaveTemplate extends Object implements Describable<JCloudsSlaveTemplate>, com.google.common.base.Supplier<JCloudsNodeMetadata>
- Author:
- Vijay Kiran
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
JCloudsSlaveTemplate.DescriptorImpl
-
Field Summary
Fields Modifier and Type Field Description boolean
allowSudo
boolean
assignPublicIp
double
cores
String
description
String
hardwareId
String
imageId
String
imageNameRegex
boolean
installPrivateKey
boolean
isPreemptible
String
keyPairName
String
labelString
String
locationId
Node.Mode
mode
String
name
String
networks
int
numExecutors
String
osFamily
String
osVersion
Integer
overrideRetentionTime
boolean
preExistingJenkinsUser
int
ram
String
securityGroups
int
spoolDelayMs
boolean
stopOnTerminate
boolean
useConfigDrive
boolean
waitPhoneHome
int
waitPhoneHomeTimeout
-
Constructor Summary
Constructors Constructor Description JCloudsSlaveTemplate(String name, String imageId, String imageNameRegex, String hardwareId, double cores, int ram, String osFamily, String osVersion, String locationId, String labelString, String description, String initScriptId, int numExecutors, boolean stopOnTerminate, String jvmOptions, boolean preExistingJenkinsUser, String fsRoot, boolean allowSudo, boolean installPrivateKey, Integer overrideRetentionTime, boolean hasOverrideRetentionTime, int spoolDelayMs, boolean assignFloatingIp, boolean waitPhoneHome, int waitPhoneHomeTimeout, String keyPairName, boolean assignPublicIp, String networks, String securityGroups, String credentialsId, String adminCredentialsId, String mode, boolean useConfigDrive, boolean isPreemptible, List<UserData> userDataEntries, String preferredAddress, boolean useJnlp, boolean jnlpProvision)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description JCloudsNodeMetadata
get()
This is where the actual provisioning (accessing the cloud provider) happens.String
getAdminCredentialsId()
String
getAdminUser()
JCloudsCloud
getCloud()
String
getCredentialsId()
Descriptor<JCloudsSlaveTemplate>
getDescriptor()
String
getFsRoot()
String
getInitScriptId()
String
getJenkinsPrivateKey()
String
getJenkinsPublicKey()
String
getJenkinsUser()
boolean
getJnlpProvision()
String
getJvmOptions()
Set<LabelAtom>
getLabelSet()
int
getNumExecutors()
String
getPreferredAddress()
boolean
getUseJnlp()
List<UserData>
getUserDataEntries()
boolean
hasOverrideRetentionTime()
JCloudsSlave
provisionSlave(TaskListener listener, org.jenkinsci.plugins.cloudstats.ProvisioningActivity.Id provisioningId)
protected Object
readResolve()
Initializes data structure that we don't persist.
-
-
-
Field Detail
-
name
public final String name
-
imageId
public final String imageId
-
imageNameRegex
public final String imageNameRegex
-
hardwareId
public final String hardwareId
-
cores
public final double cores
-
ram
public final int ram
-
osFamily
public final String osFamily
-
labelString
public final String labelString
-
description
public final String description
-
osVersion
public final String osVersion
-
locationId
public final String locationId
-
numExecutors
public final int numExecutors
-
stopOnTerminate
public final boolean stopOnTerminate
-
preExistingJenkinsUser
public final boolean preExistingJenkinsUser
-
allowSudo
public final boolean allowSudo
-
installPrivateKey
public final boolean installPrivateKey
-
overrideRetentionTime
public final Integer overrideRetentionTime
-
spoolDelayMs
public final int spoolDelayMs
-
waitPhoneHome
public final boolean waitPhoneHome
-
waitPhoneHomeTimeout
public final int waitPhoneHomeTimeout
-
keyPairName
public final String keyPairName
-
assignPublicIp
public final boolean assignPublicIp
-
networks
public final String networks
-
securityGroups
public final String securityGroups
-
mode
public final Node.Mode mode
-
useConfigDrive
public final boolean useConfigDrive
-
isPreemptible
public final boolean isPreemptible
-
-
Constructor Detail
-
JCloudsSlaveTemplate
@DataBoundConstructor public JCloudsSlaveTemplate(String name, String imageId, String imageNameRegex, String hardwareId, double cores, int ram, String osFamily, String osVersion, String locationId, String labelString, String description, String initScriptId, int numExecutors, boolean stopOnTerminate, String jvmOptions, boolean preExistingJenkinsUser, String fsRoot, boolean allowSudo, boolean installPrivateKey, Integer overrideRetentionTime, boolean hasOverrideRetentionTime, int spoolDelayMs, boolean assignFloatingIp, boolean waitPhoneHome, int waitPhoneHomeTimeout, String keyPairName, boolean assignPublicIp, String networks, String securityGroups, String credentialsId, String adminCredentialsId, String mode, boolean useConfigDrive, boolean isPreemptible, List<UserData> userDataEntries, String preferredAddress, boolean useJnlp, boolean jnlpProvision)
-
-
Method Detail
-
getCredentialsId
public String getCredentialsId()
-
getAdminCredentialsId
public String getAdminCredentialsId()
-
getInitScriptId
public String getInitScriptId()
-
getPreferredAddress
public String getPreferredAddress()
-
getUseJnlp
public boolean getUseJnlp()
-
getJnlpProvision
public boolean getJnlpProvision()
-
getCloud
public JCloudsCloud getCloud()
-
readResolve
protected Object readResolve()
Initializes data structure that we don't persist.- Returns:
- The initialized object.
-
getJenkinsUser
public String getJenkinsUser()
-
getJenkinsPrivateKey
public String getJenkinsPrivateKey()
-
getJenkinsPublicKey
public String getJenkinsPublicKey()
-
getAdminUser
public String getAdminUser()
-
getJvmOptions
public String getJvmOptions()
-
getNumExecutors
public int getNumExecutors()
-
getFsRoot
public String getFsRoot()
-
provisionSlave
public JCloudsSlave provisionSlave(TaskListener listener, org.jenkinsci.plugins.cloudstats.ProvisioningActivity.Id provisioningId) throws IOException
- Throws:
IOException
-
get
public JCloudsNodeMetadata get()
This is where the actual provisioning (accessing the cloud provider) happens.- Specified by:
get
in interfacecom.google.common.base.Supplier<JCloudsNodeMetadata>
- Specified by:
get
in interfaceSupplier<JCloudsNodeMetadata>
-
hasOverrideRetentionTime
public boolean hasOverrideRetentionTime()
-
getDescriptor
public Descriptor<JCloudsSlaveTemplate> getDescriptor()
- Specified by:
getDescriptor
in interfaceDescribable<JCloudsSlaveTemplate>
-
-