Using the latest version?
JFrog Platform User Guide


Skip to end of metadata
Go to start of metadata

Overview

Artifactory supports release management through theBamboo Artifactory Plugin.

When you run your builds usingMavenorGradlewith jobs that useGitorPerforceas your version control system, you can manually stage a release build allowing you to:

  • Change values for the release and next development version
  • Choose a target staging repository for deployment of the release, and
  • Create a VCS tag for the release.

Staged release builds can later bepromotedorrolled-back, changing their release status in Artifactory and, optionally, moving the build artifacts to a different target repository.

Inside Artifactory, the history of all build status change activities (staged, promoted, rolled-back, etc.) isrecorded and displayedfor full traceability.

When release management is enabled, the Artifactory release staging link appears on the top header bar in the job page.

Page Contents

Displaying the Release and Promotion Tab

To display theArtifactory Release & Promotiontab you need to click the small arrow indicated below.

Default Job

Release management tab moved from plugin version 1.7.0

From Bamboo Artifactory Plugin version 1.7.0, the Release Management tab was moved from thePlanpage level to theJobpage level because the process applies to artifacts in the context of a single job rather than a whole plan (which may hold several jobs).
The tab name was also changed fromArtifactory Release managementtoArtifactory Release & Promotion.


Maven Release Management

TheBamboo Artifactory Pluginmanages a release with Maven running the build only once using the following basic steps:

  1. Change the POM versions to the release version (before the build starts).

  2. Trigger the Maven build (with optionally different goals).

  3. Commit/push changes to the release branch.

  4. 接下来的发展已经改变了POM版本rsion.

  5. Commit/push changes to the trunk.

If the build fails, the plugin attempts to rollback the changes (both local and committed).

For more information including configuration of Maven Runners, and Jobs and staging a release build, please refer toBamboo Artifactory Plugin.

Configuring Maven Jobs

To enable release management in Maven jobs, edit the job configuration and check theEnable Artifactory release managementcheckbox.



Staging a Maven Release Build

Clicking on the release staging link opens a new page with configuration options for the release build:

Release Staging

The release staging page displays the last version built (the version tag is that of the root POM, and is taken from the last build that is not a release). Most of the fields in the form are populated with default values.

Version configuration controls how the plugin changes the version in the POM files (global version for all modules, version per module or no version changes).

If theCreate VCS tagcheckbox is checked (default), the plugin commits/pushes the POMs with the release version to the version control system with the commit comment. When using Git, there's also an option to create a release branch.

Click on theBuild and Release to Artifactorybutton to trigger the release build.

Target server is Artifactory Pro?

If the target Artifactory server is a Pro edition, you can change the target repository, (the default is the release repository configured in Artifactory publisher) and add a staging comment which is included in the build info deployed to Artifactory.


Gradle Release Management

TheBamboo Artifactory Pluginsupports release management when running builds with Gradle. This relies on the version property (and others) managed by thegradle.propertiesfile. The plugin reads the properties from the Artifactory release management configuration, and modifies those properties in thegradle.propertiesfile.

The plugin manages a release using the following basic steps:

  1. Modify properties in thegradle.propertiesto release values (before the build starts).

  2. Trigger the Gradle build (with optionally different tasks and options).

  3. Commit/push changes to the release branch.

  4. Modify thegradle.propertiesto the next integration values.

  5. Commit/push changes to the trunk.

Configuring Gradle Jobs

To enable Gradle release management, edit the Artifactory Gradle Task configuration and check theEnable Release Managementcheckbox.

Staging a Gradle Release Build

Once release management is enabled, the ArtifactoryRelease stagingtab appears in the top header bar on the job page.

Clicking on theRelease stagingtab opens a new page with configuration options for the release build:

Gradle Release Staging

TheRelease stagingtab displays theReleaseandNext developmentproperties configured for the job. The plugin reads these values from thegradle.propertiesfile and attempts to calculate and displayReleaseandNext integration versionin the text fields.

IfCreate VCS tagis checked (default), the plugin commits/pushes the POMs with the release version to the version control system with the commit comment. When using Git, ifUse release branchis checked, theNext release versionchanges are carried out on the release branch instead of the current checkout branch. The final section allows you to change the target repository (the default is the release repository configured in Artifactory publisher) and an optional staging comment which includes the build info deployed to Artifactory.

Click on theBuild and Release to Artifactorybutton to trigger the release build.


Promoting a Release Build

You can promote a release build after it completes successfully.

This is not a mandatory step but is very useful because it allows you to mark the build as released in Artifactory, and move or copy the built artifacts to another repository so they are available to other users.

To promote a build, browse to the build's result page and click theArtifactory Release & Promotiontab.

Artifactory Pro required

Promotion features are only available with Artifactory Pro

Promoting a Release Build

Select the target status of the build ("Released" or "Rolled-Back"). You may also enter a comment to display in the build in Artifactory.

To move or copy the build artifacts, select theTarget promotion repository.

Release management

From Bamboo Artifactory Plug-in version 1.7.0, the Artifactory Release Promotion was moved from theArtifactorytab to the newArtifactory Release & Promotiontab.


Working with Git

To work with Git, the Git plugin must be configured to build one branchAND检测到相同的地方branch.

The remote URL should allow Read+Write access.

TheBamboo Artifactory Pluginuses the Git client installed on the machine and uses its credentials to push back to the remote Git repository.

Git ConfigurationGitHub Configuration

During the release, the plugin performs the following steps:

  1. IfCreate Branchis checked, create and switch to the release branch.

  2. Commit the release version to the current branch.

  3. Create a release tag.

  4. Push the changes.

  5. Switch to the checkout branch and commit the next development version.

  6. Push the next development version to the working branch

Shallow Clones

Bamboo's Git plugin allows the use of shallow clones, however this causes the "push" not to work.

Therefore, when using the Artifactory Bamboo Plugin, you must have shallow clonesunchecked.

For more information about shallow clones, please refer togit-clone Manual Page.


Working with Perforce

Release management withBamboo Artifactory Pluginsupports Perforce when using one checkout directory.

During the release the plugin does the following:

  1. Commits the release version directly to the tag (ifCreate VCStagis checked). The release version is not committed to the working branch.
  2. Commits the next development version to the working branch

Changes

Changes are only committed if the files are modified (POM files orgradle.properties).



  • No labels