Package org.jenkinsci.plugins.vsphere
Class VSphereConnectionConfig
java.lang.Object
hudson.model.AbstractDescribableImpl<VSphereConnectionConfig>
org.jenkinsci.plugins.vsphere.VSphereConnectionConfig
- All Implemented Interfaces:
Describable<VSphereConnectionConfig>
- Author:
- Oleg Nenashev <o.v.nenashev@gmail.com>
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionVSphereConnectionConfig(String vsHost, boolean allowUntrustedCertificate, String credentialsId) Full constructor for internal use, initializes all fieldsVSphereConnectionConfig(String vsHost, String credentialsId, String httpClientClassName) -
Method Summary
Modifier and TypeMethodDescriptionbooleancom.cloudbees.plugins.credentials.common.StandardCredentialsstatic Stringstatic StringmigrateLegacyCredentials(String vsHost, String username, String password) One-time migration forvSphereCloudinstances still persisted in the legacy XML format (plainvsHost/username/passwordelements predating this class), so they keep working without the admin having to manually create a credential.voidsetAllowUntrustedCertificate(boolean allowUntrustedCertificate) voidsetHttpClientClassName(String httpClientClassName) static Class<?> Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface hudson.model.Describable
getDescriptor
-
Constructor Details
-
Method Details
-
setupGlobalHttpClientClass
-
getHttpClientClassName
-
setHttpClientClassName
-
getVsHost
-
setAllowUntrustedCertificate
@DataBoundSetter public void setAllowUntrustedCertificate(boolean allowUntrustedCertificate) -
getAllowUntrustedCertificate
public boolean getAllowUntrustedCertificate() -
getCredentialsId
-
getCredentials
@CheckForNull public com.cloudbees.plugins.credentials.common.StandardCredentials getCredentials() -
getPassword
-
getUsername
-
migrateLegacyCredentials
@CheckForNull public static String migrateLegacyCredentials(@CheckForNull String vsHost, @CheckForNull String username, @CheckForNull String password) One-time migration forvSphereCloudinstances still persisted in the legacy XML format (plainvsHost/username/passwordelements predating this class), so they keep working without the admin having to manually create a credential. Creates - or reuses, if this already ran on a previous load - aUsernamePasswordCredentialsImplin the Jenkins-global credentials store and returns its id; returnsnull(leavingcredentialsIdunset) if there is no legacy username to migrate or no credentials store is available yet.
-