Reputation: 31
I have a webapp in which a webjob is linked. Since it is linked to webapp, so it auto deploys with webapp.
My issue is that i want to deploy only webapp not webjob. Is there any way i can stop automatic deployment of webjob?
Upvotes: 2
Views: 296
Reputation: 8499
If you create your WebJob using following steps, a file named webjobs-list.json will be created under your properties folder.
Right click your project -> Add -> New Azure WebJob Project
The file will link your web application to the WebJob project. If we publish the web application, the WebJob project will also be published in the same Azure Web App.
My issue is that i want to deploy only webapp not webjob. Is there any way i can stop automatic deployment of webjob?
You can delete the webjobs-list.json file under your properties folder to remove the relationship between your web application and your WebJob. After that, the WebJob project will not be published when you publish your web application.
Since our WebJobs are exist in the app_data folder of our web application, if we check the [Remove additional files at destination] option, all the files under our web application will be deleted(include the WebJob files). If you don't want your WebJob be affected when you publish your web application, please keep the [Remove additional files at destination] option unchecked.
Upvotes: 3