Benjamin E.
Benjamin E.

Reputation: 5162

Deploy WebJobs with Web App using Web Deploy

I'm migrating a Web App project to a new Azure account. Everything works fine but the Web Jobs are not included when publishing.

webjobs-list.json is identical, the publishing profiles are identical etc., just the Web Jobs are missing.

I can deploy them individually, though.

Any idea what is wrong?

Upvotes: 0

Views: 2136

Answers (1)

Amor
Amor

Reputation: 8491

There are two things you need to check.

NO 1. The file path in webjobs-list.json is right. You could find the WebJob project file according this file.

{
  "$schema": "http://schemastore.org/schemas/json/webjobs-list.json",
  "WebJobs": [
    {
      "filePath": "../WebJob1/WebJob1.csproj"
    }
  ]
}

NO 2. Open the project file of your web application(ex. myapp.csproj). Please check whether it has been modified and lost following Import configuration section.

<Import Project="..\packages\Microsoft.Web.WebJobs.Publish.1.0.12\tools\webjobs.targets" Condition="Exists('..\packages\Microsoft.Web.WebJobs.Publish.1.0.12\tools\webjobs.targets')" />

Upvotes: 5

Related Questions