0

Goal is to deploy Azure App Service with WebDeploy package from VS2015 with all web.config transformations applied according to current solution build configuration.

I have tried adding build configuration to ARM deployment project and it works fine when you build it from Visual Studio. WebDeploy package for web project is created with correct web.config transformation applied. However if you use Deploy dialog referenced web project is always built and packaged with default build configuration (Debug) from Deployment.targets file.

Is it possible to use current solution configuration for ARM deployment?

VS2015 dialog:

Visual Studio 2015 azure resource group deploy dialog

samfromlv
  • 1,001
  • 1
  • 10
  • 17
  • do you build using the correct config (did you select "Release" instead of "Debug"?) – techmike2kx Jul 20 '16 at 09:27
  • yes, active solution configuration in VS is correct (e.g Release, not Debug). Both web project and deployment project build configuration in solution configuration are also correct – samfromlv Jul 20 '16 at 09:38

1 Answers1

1

samfromlv - I think we have a bug here, try this... open the deployment.targets file for your resource group project. Towards the top change configuration default to whatever your configuration name is (e.g. Release)

    <Configuration Condition=" '$(Configuration)' == '' ">Release</Configuration>

Try that, it may depend on what version of the SDK your project was created under so if it doesn't work lmk.

bmoore-msft
  • 8,376
  • 20
  • 22
  • It does work if I change Deployment.targets file, package is created with Release build configuration. So workaround for now is to make Deployments.target file visible in Visual Studio by editing .deployproj file and changing False to True and than change configuration by hand there before opening Deployment dialog. – samfromlv Jul 21 '16 at 10:39
  • Thanks for confirming, we do have a bug here (we're not passing in the build config) and that should be fixed in the next release... – bmoore-msft Aug 03 '16 at 15:40