Quick Info
Description
Artifactory is a repository manager that supports all software management packages, container images and Helm charts. It manages artifacts throughout a DevOps pipeline. The Artifactory plugin integrates with the Artifactory repository to import artifacts for Maven, Gradle, and Ivy builds.Quick Info
launch-artifactory-23.1134148.zip
Uploaded: 29-Jun-2022 08:01
Release Note
RFE 119754 - making Allow Insecure Connection and Download recursively inherited from component.launch-artifactory-22.1126875.zip
Uploaded: 23-Dec-2021 06:19
Release Note
Log4j issue addressed.launch-artifactory-21.1098499.zip
Uploaded: 15-Mar-2021 13:27
Release Note
Fixed APAR PH16046 - Accept groupId path for Download Latest Build for SNAPSHOT step.Summary
The Artifactory automation plugin includes steps to complete the following tasks:
- Importing artifacts from an Artifactory repository corresponding to Maven, Gradle or Ivy builds.
- Importing NuGet packages from a remote NuGet repository through an Artifactory repository.
- Attach properties to a file or folder.
- Retrieve the latest build artifact within a SNAPSHOT.
- Retrieve an archive file that contains all the artifacts for a specific build.
This plugin includes one or more steps, click Steps for step details and properties.
Compatibility
This plugin works with Jfrog Artifactory versions 2.0+ . The Artifactory Pro edition is also supported.
This plugin requires HCL Launch 6.0.1 and later.
This plugin runs on all operating systems that are supported by the HCL Launch agent.
Installation
See Installing plugins in HCL Launch for installing and removing plugins.
History
The following table describes the changes made in each plugin version.
Version | Description |
---|---|
21 | Minor enhancements |
23 | Default values for Allow Insecure Connection and Download recursively are inherited from component. |
Usage
Before you begin, the HCL Launch agent must be installed on the target system where the artifacts are downloaded.
Step palette
To access this plugin in the palette, click Repositories > Artifact > Artifactory.
Complete the following steps to create resources and define a deployment process.
- To download the files that are imported from Artifactory to the agent computer, define a resource for the agent.
- Add the agent to the new resource group.
- Hover over the row for the resource group, click Actions, and then select Add agent.
- Create components for the resources. The component process can include any of the plugin steps: Download version (Maven build), Download version (non-Maven build) or Download NuGet package.
- Add the components to the resources.
- Navigate to the resource.
- Click Actions > Add Component.
- Select the component to use.
- Create the application.
- Navigate to Applications.
- If an application does not exist, click Create New Application. You can also use an existing application.
- Enter an application name, and then click Save.
- Click the Components tab, then add the component that you created previously.
- Create an application environment.
- On the Resources page, click Create New Environment.
- Enter an environment name, and then click Save.
- Navigate to the environment editor page.
- Click the environment name, and then click Add Base Resource. Select the group that you created previously.
- Create an application process.
- Click the Processes tab.
- Add a deploy step.
- Drag the Install Component step to the process editor.
- Select the component that you created for the resource.
- Select the process for the component. For example, select Download My Maven package from Artifactory.
- Click Save to save the process.
- Run the process to test the new component.
Steps
The following process steps are available in the Artifactory plugin.
- Download Latest Build for SNAPSHOT
- Download NuGet Package
- Download version (Maven build)
- Download version (non-Maven build)
- Promote Build
- Retrieve Build Artifacts Archive
- Set Item Properties
Download Latest Build for SNAPSHOT
Retrieve the latest build artifact within a SNAPSHOT.
Name | Type | Description | Required | Property |
---|---|---|---|---|
Api Key | Password | The api key to authenticate with the Artifactory server. If using api key, username and password is ignored. | No | apiKey |
Artifactory Base URL | String | The base URL of the Artifactory server. For example: https://server.example.com:8081/artifactory. | Yes | url |
Artifactory Repository | String | The repository in Artifactory where the build artifact resides. For example:libs-snapshot-local | Yes | repo |
Classifier | String | The classifier of the version snapshot, if any. | No | classifier |
File Extension | String | The file extension of the build artifact. For example: jar | Yes | extension |
Password | Password | The password to authenticate with the Artifactory server. | No | password |
Repo Path | String | The path (group ID and artifact ID) of the build artifact. For example: org.jfrog.test/multi2 | Yes | repoPath |
User Name | String | The user name to authenticate with the Artifactory server. | No | username |
Version | String | The version of the build artifact. For example: 3.8-SNAPSHOT | Yes | version |
Download NuGet Package
Download a NuGet package from a NuGet repository.
Name | Type | Description | Required | Property |
---|---|---|---|---|
Api Key | Password | The api key to authenticate with the Artifactory server. If using api key, username and password is ignored. | No | apiKey |
Artifactory Base URL | String | The base URL of the Artifactory server. For example: https://server.example.com:8081/artifactory | Yes | artifactoryUrl |
Packages | String | A list of packages to download, separated by newline characters. Use the following format: repoPath/version | Yes | artifacts |
Repository Password | Password | The password to authenticate with Artifactory. | No | password |
Repository User name | String | The user name to authenticate with Artifactory. | No | username |
Verify Hash | Boolean | Select to verify hash values after the files are downloaded. | No | checkHash |
Download version (Maven build)
Download all files under a specified version of a repository that was built with Maven.
Name | Type | Description | Required | Property |
---|---|---|---|---|
Api Key | Password | The api key to authenticate with the Artifactory server. If using an API key, username and password is ignored. | No | apiKey |
Artifactory Base URL | String | The base URL of the Artifactory server. For example:https://server.example.com:8081/artifactory | Yes | artifactoryUrl |
Excludes | String | The patterns to use for excluding files to download. | No | excludes |
Includes | String | The patterns to use for including files to download. The wildcard ** indicates every directory and the wildcard * indicates every file. The pattern dist/**/* retrieves the entire file tree underneath the dist directory. | Yes | includes |
Repository Password | Password | The password to authenticate with Artifactory. | No | password |
Repository User name | String | The user name to authenticate with Artifactory. | No | username |
Repository name | String | The name of the repository. | No | repositoryName |
Verify Hash | Boolean | Select to verify hash values after the files are downloaded. | No | checkHash |
Versions | String | A list of versions to download, separated by newline characters. Use the following format: groupId/artifactId/version | Yes | artifacts |
Download version (non-Maven build)
Download all files under specified version of a repository (non-Maven).
Name | Type | Description | Required | Property |
---|---|---|---|---|
Api Key | Password | The api key to authenticate with the Artifactory server. If using api key, username and password will be ignored. | No | apiKey |
Artifactory Base URL | String | The base URL of the Artifactory server. For example: https://server.example.com:8081/artifactory | Yes | artifactoryUrl |
Download Recursively | Boolean | Select this box to download files and folders in subfolders of versions. Requires Artifactory Pro edition or higher. | No | recursive |
Excludes | String | The patterns to use for excluding files to download. | No | excludes |
Includes | String | The patterns to use for including files to download. The wildcard ** indicates every directory and the wildcard * indicates every file. So the pattern dist/**/* would retrieve the entire file tree underneath the dist directory. | Yes | includes |
Repository Password | Password | The password to authenticate with Artifactory. | No | password |
Repository User name | String | The user name to authenticate with Artifactory. | No | username |
Repository name | String | The name of the repository. | Yes | repositoryName |
Verify Hash | Boolean | Select to verify hash values after the files are downloaded. | No | checkHash |
Versions | String | A list of folders and subfolders to download, separated by newline characters. Use the following format: path/to/artifact/version | Yes | artifacts |
Promote Build
Change the status of a build, optionally moving or copying the build to a target repository.
Name | Type | Description | Required | Property |
---|---|---|---|---|
Api Key | Password | The api key to authenticate with the Artifactory server. If using api key, no username and password can be specified. | No | apiKey |
Artifactory Base URL | String | The base URL of the Artifactory server. For example: https://server.example.com:8081/artifactory | Yes | url |
Build Name | String | The name of the build to promote. | Yes | buildName |
Build Number | String | The number of the build to promote. | Yes | buildNumber |
CI User | String | User that invoked promotion from the CI server. | No | buildUser |
Comment | String | Comment to describe the reason for promotion. | No | buildComment |
Copy | Boolean | Select to copy instead of move when a target repository is specified. | No | buildCopy |
Include Artifacts | Boolean | Select to move or copy the build artifacts. | No | buildArtifact |
Include Dependencies | Boolean | Select to move or copy the build dependencies. | No | buildDepend |
Password | Password | The password to authenticate with the Artifactory server. | No | password |
Properties | String | A newline separated list of name=value properties to set on the promotion. For example: tester=John Smith. Specify multiple values per name with commas (escape commas with backslash \ to avoid this). For example: osVersions=Windows,Linux | No | buildProps |
Source Repository | String | The source repository that contains the build artifacts to copy or move. | Yes | buildSource |
Status | String | New build status. | Yes | buildStatus |
Target Repository | String | The target repository for the build artifacts and dependencies. | Yes | buildTarget |
User Name | String | The user name to authenticate with the Artifactory server. | No | username |
Retrieve Build Artifacts Archive
Retrieve an archive file that contains all the artifacts for a specific build.
Name | Type | Description | Required | Property |
---|---|---|---|---|
Api Key | Password | The API key to authenticate with the Artifactory server. If you enter an API key, you cannot specify a user name and password. | No | apiKey |
Archive Type | Enumeration | Select the merge type of the archive file to return. Valid types are: zip, tar, tar.gz., and tgz. | No | buildType |
Artifactory Base URL | String | The base URL of the Artifactory server. For example: https://server.example.com:8081/artifactory | Yes | url |
Build Name | String | The name of the build to download. | Yes | buildName |
Build Number | String | Specify the build to download by number. Cannot be used with Build Status. | No | buildNumber |
Password | Password | The password to authenticate with the Artifactory server. | No | password |
Repositories | String | Specify the repository to search for the build in. Separate multiple repositories with commas. | No | buildRepos |
Status | String | Specify the build to download by status. Cannot be used with Build Number. | No | buildStatus |
User Name | String | The user name to authenticate with the Artifactory server. | No | username |
Set Item Properties
Attach properties to a file or folder.
Name | Type | Description | Required | Property |
---|---|---|---|---|
Api Key | Password | The api key to authenticate with the Artifactory server. If using api key, username and password is ignored. | No | apiKey |
Artifact Path | String | The path to the artifact to set properties on. For example: libs-release-local/org/jfrog/multi1/2.7-SNAPSHOT | Yes | path |
Artifactory Base URL | String | The base URL of the Artifactory server. For example: https://server.example.com:8081/artifactory | Yes | url |
Password | Password | The password to authenticate with the Artifactory server. | No | password |
Properties | String | Specify a list of properties to set. Place each entry on a separate line. Use the following format: key=value. Separate multiple values for a key with commas, and add a backslash (\) before the following special characters: comma (,), backslash(\), vertical bar (|), and equal sign (=). Do not use a backslash before the equal sign between the key and the value or before commas used to separate multiple values. For example: osVersions=Windows\=7\,10,Linux\=16.04 LTS\ | Yes | properties |
Recursive | Boolean | Select to attach properties recursively if the Artifact Path is a directory. | No | recursive |
User Name | String | The user name to authenticate with the Artifactory server. | No | username |