3

How to deploy azure webjob using Octopus deployment?

For me, octopus says it is deployed to azure but not able to see my webjob under the website.

Can anyone help how to achieve this?

Mukil Deepthi
  • 6,072
  • 13
  • 71
  • 156

3 Answers3

2

There is a documentation on how to deploy a web job from octopus Azure Web Apps.

I was using Octopus Deploy 3.0 and in my case, I only wanted to deploy a webjob without a web app:

  • I've chosen Azure Web App Deployment Target:

Octopus Deploy WebJob - Deployment Target

  • And in the deployment section, specify the physical path.
    • For continuous job you can specify a path like that:

Octopus Deploy Continuous WebJob - Physical Path

  • For triggered job you can specify a path like that:

Octopus Deploy Triggered WebJob - Physical Path

David Peden
  • 17,596
  • 6
  • 52
  • 72
Thomas
  • 24,234
  • 6
  • 81
  • 125
  • 1
    And how do you set the schedule? – Talon May 11 '16 at 13:53
  • There are many way to set the schedule, you can add a settings.job file: see this article https://azure.microsoft.com/en-gb/documentation/articles/web-sites-create-web-jobs/#CreateScheduledCRON or you can create the schedule through the azure portal – Thomas May 11 '16 at 20:43
0

have you try to publish your web jobs to your website using Visual Studio?

One way to verify whether your web jobs has been deployed to your website/web app is to access to the Kudu site of your website. https://.scm.azurewebsites.net/azurejobs/#/jobs

Go to Debug Console (CMD), try to access D:\home\site\wwwroot\App_Data\jobs and see if there is any web jobs underneath it

juvchan
  • 6,113
  • 2
  • 22
  • 35
  • i tried to publish the webjob using visual studio and it got deployed to my website in azure. But not getting deployed by Octopus deployment. – Mukil Deepthi May 04 '15 at 07:55
  • 1
    In a corporate environment, we can't have developers deploying solutions. that's why it must be done in octopus so that it can go through all the necessary QA processes. – Talon May 11 '16 at 13:55
0

You can try using the nuspec to package your artifacts. Put you web jobs under App_Data\jobs\trigger{webjob} or App_Data\jobs\continuous{webjob} based on your job type. And then deploy using Octopus, Azure will be able to recognize it.

This might help: http://blog.amitapple.com/post/74215124623/deploy-azure-webjobs/#.VVRSANNViko

Good luck

Ryan Chu
  • 1,381
  • 13
  • 20