Marius Conjeaud
Marius Conjeaud

Reputation: 149

Azure deployment .NET app deployment scripts

My .NET Core 2 app uses build scripts (webpack), defined in .csproj file like so :

<Target Name="BuildScript" BeforeTargets="Build">
    <Exec Command="webpack" />
</Target>

This app is deployed to an Azure App Service through continuous deployment (Bitbucket). Deployment fails in "Running deployment command" obviously, because it tries to execute command "webpack".

I need my project to run webpack automatically during dev to bundle my js files ; but I don't want azure deployment to run webpack.

So what should I do ?

Thanks

Upvotes: 1

Views: 74

Answers (1)

byte
byte

Reputation: 1685

Would using Target Condition help? Something like -

Condition="'$(CONFIG)'=='DEBUG'"

Reference: https://msdn.microsoft.com/en-us/library/7szfhaft.aspx

Upvotes: 2

Related Questions