Rational Build Forge and JFrog Artifactory
BuildForge can work with Artifactory JFrog for build artifact upload.
Build Forge runs a build automation commands in the application server to generate software package build and deliver. The Build Forge agents deployed across various platforms may be producing builds of the respective software applications, modules or entire software packages. These builds are generated in the form of binary packages that are considered as artifacts. The Build Forge users across software assembly line would intend to securely store these artifacts generated in a repository and to be able to retrieve in real-time on the build forge agent machine.
Build Forge offers a capability to integrate with the Artifactory Repository Manager for processing the build artifacts. The Artifactory Repository Manager is a 3rd-Party artifacts management application by JFrog, that facilitates seamless management of binary artifacts produced by different Build tools such as Build Forge etc.
The Build Forge customers can leverage the capabilities of the Artifactory Repository Manager by integrating it with the Build Forge.
Prerequisite
- A hosted and running Artifactory Repository Manager should be available.
- The cURL command must be available on the Build Forge Agent machine where upload and download is to be performed.
Creating Environment Variables
Environment variables are set of dynamic values that runs the uploading and downloading process of artifacts from Build Forge to Artifactory and vice-verse. You must define these environment variables in the Build Forge with the variable name pointing to artifactory repository locations.
- Login to Build Forge and navigate to the Console tab.
- On the left pane, select Environments.
The Environment page is displayed. In this page, you will be creating a new Environment and add the environment variables for integrating Build Forge with Artifactory.
- Click Add Environment to create a new environment. Or By default, the New Environment page is available at the lower bottom of the page for creating a new environment.
- In the Name box, type an appropriate name for the integration environment.
- Click Save Environment. The newly added environment page is displayed.
- Click Add Environment Variable. The new environment variable page is available at the lower bottom of the page.
- Under the new environment, create each environment variable as illustrated in the following table.
Variable Name
Value
Action On Project ARTIFACTORY_URL
IP address of the Artifactory server.
For example: http://<<IP Address>>/artifactory.
Default Default ARTIFACTORY_REPO
Name of the repository in the Artifactory, where you upload/download the binary files.
For example: project libraries
Default Default ARTIFACTORY_USER
The user credentials having access privilege to Artifactory repository.
For example: Admin
Default Default ARTIFACTORY_PASSWORD
Required. Password to login and access Artifactory repository.
Assign Hidden Default ARTIFACTORY_SOURCE_FILE_PATH
Artifactory source file location (Path) from where the library files are uploaded to Artifactory repository. You can dynamically change this repository location during upload.
Default Default ARTIFACTORY_TARGET_FILE_PATH
Specific target location in the repository of the Artifactory application where the artifacts is intended to be uploaded/downloaded. You can dynamically change this repository location during upload or download process.
Default Default ARTIFACTORY_DOWNLOAD_PATH The location on your system where you want to download an artifact from the Artifactory. Default Default
Uploading and Downloading Artifacts
Artifact upload and download can be performed by executing dot commands in the Build Forge application. In a project, while creating step, ensure to select the Artifactory environment from the Environment drop-down list to upload or download the artifacts files by running the following commands:
- Upload command .artifactupload
- Download command .artifactdownload
.bset env "ARTIFACTORY_TARGET_FILE_PATH=builds/$BF_TAG"
.bset env “ARTIFACTORY_SOURCE_FILE_PATH=$BF_ROOT/$BF_TAG.zip”
.artifactupload