Share via

Fix for: "WebJob cannot be added from portal if deployment form source control is configured." Error?

Eric Giddings 1 Reputation point
4 Dec 2019, 12:05 am

I use Git as a deployment method so I assume that is the source control deployment they are mentioning.

This is an error that only started coming up in the past few months as I have already created many WebJobs from the portal.

I have seen this StackOverflow (https://stackoverflow.com/questions/57972072/webjob-cannot-be-added-from-portal-if-deployment-form-source-control-is-configur) but does MS have a proper work around? Do they have a solution in the works?

It is a pain that the WebJob UI does not work for me any more.

Also, there is a spelling error in their error? Makes me wonder if there is much thought put into this error.

Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
7,933 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Ryan Hill 28,716 Reputation points Microsoft Employee
    4 Dec 2019, 8:13 pm

    Hi @Eric Giddings

    This restriction was recently added by the product team due to an unexpected behavior when trying to configure WebJobs when Run From Package is enabled.

    Therefore, if you want to continue to deploy from the portal, you'll have to disconnect the portal deployment center, deploy to the portal, and re-enable. Otherwise, you can either deploy via Visual Studio, through kudu or an Azure DevOps CI/CD pipeline.

    1 person found this answer helpful.

  2. BTardif-[MSFT] 356 Reputation points Microsoft Employee
    31 Dec 2019, 10:04 pm

    If you have source control configured with your application, the webjobs should be deployed as part of the source control integration.

    Form App Service perspective a webjob is just part of the content of the app.

    If you deploy a webjob through the portal (before we added the restriction to block it) and then had a commit to your source control, then the webjob would be removed since it wasn't part of the payload being published by source control.

    The right way to do this is to make sure webjobs are part of your solution.

    As a workaround, you can deploy webjobs through FTP/FTPS but keep in mind they will be removed the moment source control does the next deployment.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.