New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow finer control over config transforms #292
Comments
What if we created a special syntax that looked like this:
Which means:
Then you could edit this specification, add/remove the transforms you want, and change the order that they run in. This setting could also be bound to a variable, so different transforms could be run for different environments. |
Very team-city - I like it. The other edge case (which is where I found this initially) is that upper/lowercase names should be de-duped, even if doing it this way with variables. In our environment, I had an environment called "release", and it was running the transform "web.Release.config" then "web.release.config" and failing the second time due to the transforms performed. Probably should have recognised both as being identical. |
Popped into the 2.1 bucket, since we'd like to address this soon but won't hold up 2.0 for it. Just a thought, and maybe a workaround for the short term - it might be possible to invoke transforms through PowerShell in Deploy.ps1? |
For my use case, I just renamed our environment from "release" to "release.deepend.local" - sorted it right out for now, and I agree, not something worth holding up the main release of 2.0 for. |
Moving to the backlog to consider in the next cut, doesn't fit our current goals for 2.2. |
+1 to be able to handle the convention how octopus finds the config to use for transform. Cause our problem is that we have like web.test.config and web.test.en.confg and web.test.no.config (depending in language) , It's hosted as seperated site but uses same codebase except for web.configs. So our convention would be something like Web.#{Octopus.Environment.Name}.#{Site.Language}.config |
Here is something to consider when thinking about this. We use NServiceBus for computing cluster. The XML Config for all those xml elements are like |
Just a couple of suggestions which would solve some of the customization we've made ourselves around this area.
|
I'm a little confused on this proposal: Would this convention allow for the running of a Web.QA.config in the event that I wanted to share a config between environments named Web.QA1.config and Web.QA2.config? This is an enhancement I would like to see happen as multiple similar but unique environments that would benefit from shared transforms is a frequent case for me. |
@plukevdh yes, you'd just define a variable called 'SharedConfigName' with a value of 'QA' scoped to QA1 and QA2. Then define the transform as:
|
Merged Jeff's implementation into 2.5 - great one @jeff-french! |
@PaulStovell Will this allow us to define a common transform that is run in a subset of environments? For example, for one project the testing / production transforms look similar but the development one is quite different so we can't use web.release.config I'd like to be able to run If this implementation gracefully skips undefined transformation files I could do something like:
And leave |
@crossetj that's exactly how it will work. |
Hi Paul I have a similar, but different need from Octopus. Let's say (because I do) have multiple test environments. Systest-01..Systest-50 (big org). I'd like to be able to get octopus to use the Systest part and ignore the number index. Is this possible? Matt |
@MattLaw75 So you want the Try this:
Now when Octopus processes the additional config transforms for that deployment step the |
Beautifully simple - sorry I didn't think of it myself, still learning :) |
No problem. Glad I could help. :) |
@PaulStovell It would be great if this would be added to the documentation at http://docs.octopusdeploy.com/display/OD/Configuration+files with some examples of expressions you can use. This page was the only reference i could find regarding this type of configuration. It would also be great with some better Task logging when you resolve "Additional transforms". If a path is misspelled or something it is just silently skipped. A bit of Info/Verbose logging to give a hint that a path has been skipped would be great. |
This thread has been automatically locked since there has not been any recent activity after it was closed. If you think you've found a related issue, please contact our support team so we can triage your issue, and make sure it's handled appropriately. |
When trying to keep projects compatible with multiple different processes / systems, sometimes it's necessary to keep some transforms around that you don't necessarily want run by convention on deploy.
It would be great if there was an option, when turning on config transforms, to disable the convention options, and only run an explicit transform (I believe the explicit transform is possible, but the convention part is not)
The text was updated successfully, but these errors were encountered: