Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Next challenges

Recent achievements

  • Global
  • Personal


  • Give kudos
  • Received
  • Given


  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Deployment of same artifact to different environements

Hi All

Just wondering if anyone can give me some ideas on solving an issue we currently have with our Bamboo builds and subsequent deployments.

We have a single .Net website project that needs to be deployed in a couple of "flavours". 

  1. the main production instance
  2. a demo instance
  3. a training instance

Each of these instances have a slightly different configuration.

At the moment, when we run a release build the project esssentially gets built three times, once for each instance, which generates three seperate artifacts. This process chews up quite a lot of build time, and vastly increase the space used for build/artifact storage.

Is it possible to have the build generate a single artifact, and then in a post-build task, or pre-deployment task, make the necessary configuration changes for each instance?




2 answers

1 accepted

0 votes
Answer accepted
Jimmy Seddon Community Leader Aug 10, 2020

Hi Phil,

Welcome to the Community!

At a high level you have already described exactly what needs to be done.  The question that I feel needs to be asked at this point is "what" is different configuration-wise between the three artifacts.  I know for some of our older .net websites, we are storing configuration changes per environment in a separate repository and we are using powershell scripts to replace environment specific configuration settings in the app.config and web.config files ahead of deploying to the selected environment.  Not sure if that suggestion will be helpful or not.

Good Luck!


@Jimmy Seddon yes, I think it's just the configs that are being transformed as part of the build.

The thing I'm trying to solve is not building the same project over and over again.

Sorry, I'm not very clear on the build options available in Bamboo. Could we have seperate build that does the config transforms and outputs those as different artifacts? Then bring the main build artifact and the config build artifact together in a deployment plan?




Jimmy Seddon Community Leader Aug 10, 2020

Hey @Phil Carter,

Ok let me try to explain what we are doing a little more clearly.  I want to preface this with what we are doing is not pretty but it works and we haven't found a better way ourselves.  We only build the .Net website once with values for the development environment, and save that as our built artifact.

Then, we have a deployment project with QA, Staging and Production environments.  When we execute one of those environments from our deployment project in Bamboo it does the following:

1. Downloads the artifact from the build plan (which contains dev values from our single build)

2. Checks out our configuration repository that contains all config values for all environments.

3. Run a PowerShell script that based on the environment we are executing does XML find & Replace to update the development values to what they should be set to for the environment we are executing.

4. Deploy the website to the correct servers.


So we are in fact only building it once.  We aren't using proper web.config transforms to map the configurations at build time we are doing it using a Powershell script at deployment time.

I hope that makes more sense for you.


@Jimmy Seddon yep, that makes sense and will give me something to work on.




Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Bamboo

Bamboo 7.2 is here!

I'm happy to announce that Bamboo 7.2 has been released and it’s overflowing with awesome new features. This will be the last major Server release before the launch of Bamboo DC. Bamboo logs We...

489 views 5 7
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you