Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

AppHarbor Web.config transforms not being applied

Tags:

appharbor

I am developing an application in ServiceStack and am trying to sort out deployment on AppHarbor, however for some reason my web.config transforms are not being applied.

I had originally a Web.AppHarbor.config file and changed the Environment Setting to "AppHarbor" - once this failed to work after several updates, I gave up and changed the Environment setting to "Release" and copied the desired transformations into the Web.Release.Config file.

App gets deployed OK but config settings do not reflect the values in the transform file (I verify this by login on with twitter and seeing the callback url for Twitter Auth still tries to redirect me to localhost, which is one of the settings I change in my transform file)

I have also tried the transform tester tool and all works as expected.

Manually publishing the web application to a local folder correctly applies the transformations according to the selected configuration

Does anyone have this working? Is there something obvious I'm missing?

Thanks

like image 410
Teto Avatar asked Feb 06 '13 21:02

Teto


2 Answers

It sounds like the Web.Release.config file is not included in the build output. You need to set the Build Action attribute to Content to include it in the build output.

You can confirm whether the file is included in the output by downloading the build from the log page.

like image 117
runesoerensen Avatar answered Nov 10 '22 03:11

runesoerensen


I stumbled across this post because I was seeing the same lack of action myself. Upon closer inspection (about 15 times that is) of my Web.Release.config I realized one of the nodes in my config file was not marked xdt:Transform="Replace". Unsurprisingly it did nothing when deployed.

like image 44
Chris Marisic Avatar answered Nov 10 '22 03:11

Chris Marisic