slow-cheetah icon indicating copy to clipboard operation
slow-cheetah copied to clipboard

How do I disable SlowCheetah transforms for CI/CD builds but keep them for local builds?

Open lhersman opened this issue 4 years ago • 1 comments

Hey all,

I have a .NET Web Application with some various config transforms (web.dev.config, web.qa.config, ect). These are great for local debugging. However, for our CI/CD pipeline, we want to build only once and deploy that same artifact across the environments, and thus would like to do the transform step on deploy instead of build.

This is easily doable with the FileTransform Azure DevOps task, but it constantly fails when I try it. After some research I found this which states that it doesn't like it when the transform is applied twice, so disable it on CI/CD build.

I have tried every MsBuild flag I could find to turn off the transforms on build and none of them seem to work. I tried /p:TransformWebConfigEnabled=false as the above issue stated, as well as the following:

/p:ProfileTransformWebConfigEnabled=false /p:MarkWebConfigAssistFilesAsExclude=false /p:AutoParameterizationWebConfigConnectionStrings=false /p:IsWebConfigTransformDisabled=true

but when I dig into the build logs on Azure DevOps the ScTransformAppConfig section always appears and does it's thing. Is there an MsBuild argument I havent tried to disable this? Again, I'd still like it to work for local builds, just not in the pipeline. Thanks!

lhersman avatar Jul 10 '20 21:07 lhersman

I come here finding how SlowCheetah work into CI/CD ... maybe SlowCheetah can't make it ???

rolivares avatar Jan 15 '21 13:01 rolivares