0
votes

Currently I am using bamboo for maven builds. Artifactory is being used for artifact deployment. During initial bamboo setup, artifactory admin user and password got configured in maven settings.xml. Due to admin privileges, bamboo plan everytime overwrites artifact at the time of deployment. I would like to stop this artifact overwrite behavior.

I would like to:

  • Replace admin account in settings.xml with another account which will have only artifact upload access in Artifactory.
  • Teams will use their own generic ID in bamboo plans for uploading artifacts to Artifactory.

Is there any other standard solution to fix this overwrite problem.? I am not sure how teams will be able to pass their artifactory generic id and password for maven build in bamboo. And is this industry used approach while dealing with maven builds for multiple teams in Bamboo/Jenkins.?

Thanks, Pushpraj

1

1 Answers

2
votes

You can configure different Artifactory users for each of your Bamboo Plans. Here's how you can achieve this:

  1. Install the Bamboo Artifactory Plugin on your Bamboo instance.

  2. The plugin adds an "Artifactory" section in Bamboo's Administration. Configure the details of your Artifactory server there.

  3. The plugin also adds a few new Bamboo tasks. One of them is "Artifactory Maven". This task allows you to run a maven build, while resolving the build dependencies and deploying the build artifacts to Artifactory. For the deployment and resolution, the task configuration allows you to override the Artifactory user defined in the Bamboo administration. This allows you to deploy artifacts from different plans using different Artifactory users.

Important: the deployment to Artifactory happens during maven's install goal.

You can read more about the plugin in the Bamboo Artifactory Plugin User Guide