Azure Webjob publish takes entire bin folder contents

306 Views Asked by At

I was trying "Publish as azure webjob" option on a webjob project. It copies entire bin contents to cloud. It includes other unwanted dlls or files also (example: unit test dlls or any other file in the bin folder). How can we include only those contents which are required by my webjob?

For a webAPI project I can find a option as follows: (but not for WebJob)

enter image description here

1

There are 1 best solutions below

2
On

Check the project release/ publish settings. You can exclude test project from 'Configuration Manager'. Unit test project should only be enabled in Debug mode. You can also use [Ignore] switch. It's a build switch and will ignore the tests from being published.