public class AuthenticatedZipExtractionInstaller extends ToolInstaller
ToolInstaller that downloads a zip or tar.gz and unpacks it in
order to install a tool. If the tool is already present, it will only be
re-downloaded/re-unpacked if the URL is newer than the existing content. The
download supports HTTP basic authentication.| Modifier and Type | Class and Description |
|---|---|
static class |
AuthenticatedZipExtractionInstaller.DescriptorImpl
Descriptor for the
AuthenticatedZipExtractionInstaller. |
ToolInstaller.ToolInstallerEntry, ToolInstaller.ToolInstallerListExtensionPoint.LegacyInstancesAreScopedToHudsontool| Constructor and Description |
|---|
AuthenticatedZipExtractionInstaller(String label)
Constructor that sets mandatory fields.
|
| Modifier and Type | Method and Description |
|---|---|
protected Date |
downloadOnFromMaster(org.apache.commons.httpclient.URI uri,
Long timestampOfLocalContents,
String usernameOrNull,
String passwordOrNull,
FilePath dir,
TaskListener logOrNull,
String nodeName) |
protected Date |
downloadOnRemoteNode(org.apache.commons.httpclient.URI uri,
Long timestampOfLocalContents,
String usernameOrNull,
String passwordOrNull,
FilePath dir,
TaskListener logOrNull,
String nodeName) |
String |
getCredentialsId()
ID of the credentials to use when doing the download.
|
String |
getSubdir()
Subdirectory within the zip/tar.gz where the tool's binaries are located.
|
String |
getUrl()
URL of a zip/tar.gz file which should be downloaded and unpacked if the
tool is missing or out of date.
|
protected com.cloudbees.plugins.credentials.common.StandardCredentials |
lookupConfiguredCredentials(String urlHostOrNullOrEmpty) |
FilePath |
performInstallation(ToolInstallation tool,
Node node,
TaskListener log) |
void |
setCredentialsId(String credentialsId)
Sets
getCredentialsId(). |
void |
setSubdir(String subdir)
Sets
getSubdir(). |
void |
setUrl(String url)
Sets
getUrl(). |
appliesTo, getDescriptor, getLabel, preferredLocation, setTool@DataBoundConstructor public AuthenticatedZipExtractionInstaller(String label)
label - The ToolInstaller.getLabel().@CheckForNull public String getUrl()
@DataBoundSetter public void setUrl(@Nullable String url)
getUrl().url - New value.@CheckForNull public String getCredentialsId()
@DataBoundSetter public void setCredentialsId(@Nullable String credentialsId)
getCredentialsId().credentialsId - New value.@CheckForNull public String getSubdir()
@DataBoundSetter public void setSubdir(@Nullable String subdir)
getSubdir().subdir - New value.public FilePath performInstallation(@Nonnull ToolInstallation tool, @Nonnull Node node, @CheckForNull TaskListener log) throws IOException, InterruptedException
performInstallation in class ToolInstallerIOExceptionInterruptedExceptionprotected com.cloudbees.plugins.credentials.common.StandardCredentials lookupConfiguredCredentials(@CheckForNull String urlHostOrNullOrEmpty) throws ExtraToolInstallersException
ExtraToolInstallersExceptionprotected Date downloadOnFromMaster(@Nonnull org.apache.commons.httpclient.URI uri, @CheckForNull Long timestampOfLocalContents, @CheckForNull String usernameOrNull, @CheckForNull String passwordOrNull, @Nonnull FilePath dir, @CheckForNull TaskListener logOrNull, @Nonnull String nodeName) throws IOException, InterruptedException
IOExceptionInterruptedExceptionprotected Date downloadOnRemoteNode(@Nonnull org.apache.commons.httpclient.URI uri, @CheckForNull Long timestampOfLocalContents, @CheckForNull String usernameOrNull, @CheckForNull String passwordOrNull, @Nonnull FilePath dir, @CheckForNull TaskListener logOrNull, @Nonnull String nodeName) throws IOException, InterruptedException
IOExceptionInterruptedExceptionCopyright © 2016–2022. All rights reserved.