用于部署WebJob的Azure ARM模板 [英] Azure ARM Templates to deploy WebJobs
本文介绍了用于部署WebJob的Azure ARM模板的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
所有人
有人可以帮助我使用ARM模板部署WebJob吗?
Could anyone please help me on deploying WebJobs using ARM Templates ?
谢谢, 拉贾拉姆.
推荐答案
A template shared by David Ebbo shows how to deploy Webjobs using Arm Templates.
在此模板中,触发的Web作业链接到由同一模板部署的网站.网络作业是jobCollection的一部分.此jobCollection使用"dependsOn"节点链接到其父网站.
In this template, a triggered webjob is linked to a website deployed by the same template. A webjob is a part of a jobCollection. This jobCollection is linked to it's parent website using the "dependsOn" node.
{
"apiVersion": "2014-08-01-preview",
"name": "[parameters('jobCollectionName')]",
"type": "Microsoft.Scheduler/jobCollections",
"dependsOn": [
"[resourceId('Microsoft.Web/Sites', parameters('siteName'))]"
],
"location": "[parameters('siteLocation')]",
"properties": {
"sku": {
"name": "standard"
},
"quota": {
"maxJobCount": "10",
"maxRecurrence": {
"Frequency": "minute",
"interval": "1"
}
}
},
"resources": [
{
"apiVersion": "2014-08-01-preview",
"name": "DavidJob",
"type": "jobs",
"dependsOn": [
"[resourceId('Microsoft.Scheduler/jobCollections', parameters('jobCollectionName'))]"
],
"properties": {
"startTime": "2015-02-10T00:08:00Z",
"action": {
"request": {
"uri": "[concat(list(resourceId('Microsoft.Web/sites/config', parameters('siteName'), 'publishingcredentials'), '2014-06-01').properties.scmUri, '/api/triggeredjobs/MyScheduledWebJob/run')]",
"method": "POST"
},
"type": "http",
"retryPolicy": {
"retryType": "Fixed",
"retryInterval": "PT1M",
"retryCount": 2
}
},
"state": "enabled",
"recurrence": {
"frequency": "minute",
"interval": 1
}
}
}
]
}
关于
这篇关于用于部署WebJob的Azure ARM模板的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文