2016-11-17 4 views
1

Я добавил пару runbook в Azure автоматизации. Теперь, когда я смотрю на сценарий автоматизации работы с лазурной сетью, я вижу, что он включает в себя все выполненные задания и так много других вещей. Я чувствую, что здесь что-то не так. Почему все завершенные работы были частью сценария автоматизации? Проверьте скрипт ниже.Почему все завершенные работы были частью сценария автоматизации Azure?

{ 
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#", 
"contentVersion": "1.0.0.0", 
"parameters": { 
    "automationAccounts_Test2_Automation_sku": { 
     "defaultValue": null, 
     "type": "SecureObject" 
    }, 
    "automationAccounts_Test2_Automation_name": { 
     "defaultValue": "test3-Automation", 
     "type": "String" 
    }, 
    "storageAccounts_ordersbloblogsdut_name": { 
     "defaultValue": "ordersbloblogsdut", 
     "type": "String" 
    }, 
    "runbooks_PurgeLogs_name": { 
     "defaultValue": "test3-Automation/PurgeLogs", 
     "type": "String" 
    }, 
    "runbooks_deleteItems_name": { 
     "defaultValue": "test3-Automation/deleteItems", 
     "type": "String" 
    }, 
    "modules_Azure_name": { 
     "defaultValue": "test3-Automation/Azure", 
     "type": "String" 
    }, 
    "modules_Azure.Storage_name": { 
     "defaultValue": "test3-Automation/Azure.Storage", 
     "type": "String" 
    }, 
    "modules_AzureRM.Automation_name": { 
     "defaultValue": "test3-Automation/AzureRM.Automation", 
     "type": "String" 
    }, 
    "modules_AzureRM.Compute_name": { 
     "defaultValue": "test3-Automation/AzureRM.Compute", 
     "type": "String" 
    }, 
    "modules_AzureRM.Profile_name": { 
     "defaultValue": "test3-Automation/AzureRM.Profile", 
     "type": "String" 
    }, 
    "modules_AzureRM.Resources_name": { 
     "defaultValue": "test3-Automation/AzureRM.Resources", 
     "type": "String" 
    }, 
    "modules_AzureRM.Sql_name": { 
     "defaultValue": "test3-Automation/AzureRM.Sql", 
     "type": "String" 
    }, 
    "modules_AzureRM.Storage_name": { 
     "defaultValue": "test3-Automation/AzureRM.Storage", 
     "type": "String" 
    }, 
    "modules_Microsoft.PowerShell.Core_name": { 
     "defaultValue": "test3-Automation/Microsoft.PowerShell.Core", 
     "type": "String" 
    }, 
    "modules_Microsoft.PowerShell.Diagnostics_name": { 
     "defaultValue": "test3-Automation/Microsoft.PowerShell.Diagnostics", 
     "type": "String" 
    }, 
    "modules_Microsoft.PowerShell.Management_name": { 
     "defaultValue": "test3-Automation/Microsoft.PowerShell.Management", 
     "type": "String" 
    }, 
    "modules_Microsoft.PowerShell.Security_name": { 
     "defaultValue": "test3-Automation/Microsoft.PowerShell.Security", 
     "type": "String" 
    }, 
    "modules_Microsoft.PowerShell.Utility_name": { 
     "defaultValue": "test3-Automation/Microsoft.PowerShell.Utility", 
     "type": "String" 
    }, 
    "modules_Microsoft.WSMan.Management_name": { 
     "defaultValue": "test3-Automation/Microsoft.WSMan.Management", 
     "type": "String" 
    }, 
    "modules_Orchestrator.AssetManagement.Cmdlets_name": { 
     "defaultValue": "test3-Automation/Orchestrator.AssetManagement.Cmdlets", 
     "type": "String" 
    }, 
    "schedules_PurgeLogsSchedule_name": { 
     "defaultValue": "test3-Automation/PurgeLogsSchedule", 
     "type": "String" 
    }, 
    "schedules_deleteItemsSchedule_name": { 
     "defaultValue": "test3-Automation/deleteItemsSchedule", 
     "type": "String" 
    }, 
    "jobs_dddefbc6_ce31_4baf_8289_091694ff6605_name": { 
     "defaultValue": "test3-Automation/dddefbc6-ce31-4baf-8289-091694ff6605", 
     "type": "String" 
    }, 
    "jobs_d6d7ae51_1fb2_46f1_86c8_251279e093df_name": { 
     "defaultValue": "test3-Automation/d6d7ae51-1fb2-46f1-86c8-251279e093df", 
     "type": "String" 
    }, 
    "jobs_1d2d3f92_5524_4a91_9c47_8e236bc8d46d_name": { 
     "defaultValue": "test3-Automation/1d2d3f92-5524-4a91-9c47-8e236bc8d46d", 
     "type": "String" 
    }, 
    "jobs_8bf70d4a_3143_4d6e_91ef_14f0d33c9235_name": { 
     "defaultValue": "test3-Automation/8bf70d4a-3143-4d6e-91ef-14f0d33c9235", 
     "type": "String" 
    }, 
    "jobs_589caa59_46d5_44d7_8b9d_d754364f09fa_name": { 
     "defaultValue": "test3-Automation/589caa59-46d5-44d7-8b9d-d754364f09fa", 
     "type": "String" 
    }, 
    "jobs_fa6d44b2_3c23_41a2_b14d_81a3f3b1e279_name": { 
     "defaultValue": "test3-Automation/fa6d44b2-3c23-41a2-b14d-81a3f3b1e279", 
     "type": "String" 
    }, 
    "jobs_a7be24d1_588e_4203_a7ae_40c7799e8a63_name": { 
     "defaultValue": "test3-Automation/a7be24d1-588e-4203-a7ae-40c7799e8a63", 
     "type": "String" 
    }, 
    "jobs_75fdb298_12d6_47d9_9ef9_769103641370_name": { 
     "defaultValue": "test3-Automation/75fdb298-12d6-47d9-9ef9-769103641370", 
     "type": "String" 
    }, 
    "jobs_21459a62_bda8_48a1_ac77_fc77edb7277c_name": { 
     "defaultValue": "test3-Automation/21459a62-bda8-48a1-ac77-fc77edb7277c", 
     "type": "String" 
    }, 
    "jobs_68389ebd_d78c_4540_b1e3_fc918c3d7a6f_name": { 
     "defaultValue": "test3-Automation/68389ebd-d78c-4540-b1e3-fc918c3d7a6f", 
     "type": "String" 
    }, 
    "jobs_c9eda4f3_b727_4e1c_8232_276fc1738cac_name": { 
     "defaultValue": "test3-Automation/c9eda4f3-b727-4e1c-8232-276fc1738cac", 
     "type": "String" 
    }, 
    "jobs_84805e33_6b65_4527_872f_94c01d4bd52f_name": { 
     "defaultValue": "test3-Automation/84805e33-6b65-4527-872f-94c01d4bd52f", 
     "type": "String" 
    }, 
    "jobs_b8f9e3a7_b8c9_4ace_b005_cb7a8a8042f4_name": { 
     "defaultValue": "test3-Automation/b8f9e3a7-b8c9-4ace-b005-cb7a8a8042f4", 
     "type": "String" 
    }, 
    "jobs_b415353f_da2a_40b3_88b0_5b99bf00db69_name": { 
     "defaultValue": "test3-Automation/b415353f-da2a-40b3-88b0-5b99bf00db69", 
     "type": "String" 
    }, 
    "jobs_660b1e97_5451_471e_ad6e_f9e2b3fbdf31_name": { 
     "defaultValue": "test3-Automation/660b1e97-5451-471e-ad6e-f9e2b3fbdf31", 
     "type": "String" 
    }, 
    "jobs_9c3f026b_e7d1_45b0_95b4_6884ea560b9d_name": { 
     "defaultValue": "test3-Automation/9c3f026b-e7d1-45b0-95b4-6884ea560b9d", 
     "type": "String" 
    }, 
    "jobs_8d650ae4_8f7d_407f_b9c9_31e6bb902d3d_name": { 
     "defaultValue": "test3-Automation/8d650ae4-8f7d-407f-b9c9-31e6bb902d3d", 
     "type": "String" 
    }, 
    "jobs_f37e4e76_3fff_488c_9d5c_5b6539d626e0_name": { 
     "defaultValue": "test3-Automation/f37e4e76-3fff-488c-9d5c-5b6539d626e0", 
     "type": "String" 
    }, 
    "jobs_2e18b738_b549_45cc_ac2f_90708feeff1d_name": { 
     "defaultValue": "test3-Automation/2e18b738-b549-45cc-ac2f-90708feeff1d", 
     "type": "String" 
    }, 
    "jobs_a754695e_3cd2_4aec_878f_8cd9a5728b95_name": { 
     "defaultValue": "test3-Automation/a754695e-3cd2-4aec-878f-8cd9a5728b95", 
     "type": "String" 
    }, 
    "jobs_b92a4ff4_c4ca_472c_9031_e4b456f77f30_name": { 
     "defaultValue": "test3-Automation/b92a4ff4-c4ca-472c-9031-e4b456f77f30", 
     "type": "String" 
    }, 
    "jobs_91a2d834_8c37_461d_acce_473594bd3f5d_name": { 
     "defaultValue": "test3-Automation/91a2d834-8c37-461d-acce-473594bd3f5d", 
     "type": "String" 
    }, 
    "jobs_72014de4_d6fb_4d57_b9b9_5c8fd9cde973_name": { 
     "defaultValue": "test3-Automation/72014de4-d6fb-4d57-b9b9-5c8fd9cde973", 
     "type": "String" 
    }, 
    "jobs_3de2322a_f04d_452c_aed6_7650e0d3eaa2_name": { 
     "defaultValue": "test3-Automation/3de2322a-f04d-452c-aed6-7650e0d3eaa2", 
     "type": "String" 
    }, 
    "jobs_23e0e810_98fc_4e78_af4c_cdc0da2b8d77_name": { 
     "defaultValue": "test3-Automation/23e0e810-98fc-4e78-af4c-cdc0da2b8d77", 
     "type": "String" 
    }, 
    "jobs_d2428518_fd4c_41d6_88f4_27402401b4dd_name": { 
     "defaultValue": "test3-Automation/d2428518-fd4c-41d6-88f4-27402401b4dd", 
     "type": "String" 
    }, 
    "jobs_1d61307a_2e25_4064_87f5_e83e37d6ff26_name": { 
     "defaultValue": "test3-Automation/1d61307a-2e25-4064-87f5-e83e37d6ff26", 
     "type": "String" 
    }, 
    "jobs_cc668047_7090_4946_a81a_63270eadaf98_name": { 
     "defaultValue": "test3-Automation/cc668047-7090-4946-a81a-63270eadaf98", 
     "type": "String" 
    }, 
    "jobs_a11ecdbf_5b10_4fa6_add5_8541838f0ded_name": { 
     "defaultValue": "test3-Automation/a11ecdbf-5b10-4fa6-add5-8541838f0ded", 
     "type": "String" 
    }, 
    "jobs_825455ac_8f5e_4611_8a30_11607b566a69_name": { 
     "defaultValue": "test3-Automation/825455ac-8f5e-4611-8a30-11607b566a69", 
     "type": "String" 
    }, 
    "jobSchedules_77c19c90_ed86_4a1c_96d3_c41746833890_name": { 
     "defaultValue": "test3-Automation/77c19c90-ed86-4a1c-96d3-c41746833890", 
     "type": "String" 
    }, 
    "jobSchedules_30987e26_6340_4ba2_9f75_42944881c9d6_name": { 
     "defaultValue": "test3-Automation/30987e26-6340-4ba2-9f75-42944881c9d6", 
     "type": "String" 
    } 
}, 
"variables": {}, 
"resources": [ 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation'.", 
     "type": "Microsoft.Automation/automationAccounts", 
     "name": "[parameters('automationAccounts_Test2_Automation_name')]", 
     "apiVersion": "2015-10-31", 
     "location": "southcentralus", 
     "properties": { 
      "sku": "[parameters('automationAccounts_Test2_Automation_sku')]" 
     }, 
     "resources": [], 
     "dependsOn": [] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourceGroups/Test-data/providers/Microsoft.Storage/storageAccounts/ordersbloblogsdut'.", 
     "type": "Microsoft.Storage/storageAccounts", 
     "sku": { 
      "name": "Standard_LRS", 
      "tier": "Standard" 
     }, 
     "kind": "BlobStorage", 
     "name": "[parameters('storageAccounts_ordersbloblogsdut_name')]", 
     "apiVersion": "2016-01-01", 
     "location": "westus", 
     "tags": {}, 
     "properties": { 
      "accessTier": "Cool" 
     }, 
     "resources": [], 
     "dependsOn": [] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/runbooks/PurgeLogs'.", 
     "type": "Microsoft.Automation/automationAccounts/runbooks", 
     "name": "[parameters('runbooks_PurgeLogs_name')]", 
     "apiVersion": "2015-10-31", 
     "location": "southcentralus", 
     "properties": { 
      "runbookType": "Script", 
      "logVerbose": false, 
      "logProgress": false 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/runbooks/deleteItems'.", 
     "type": "Microsoft.Automation/automationAccounts/runbooks", 
     "name": "[parameters('runbooks_deleteItems_name')]", 
     "apiVersion": "2015-10-31", 
     "location": "southcentralus", 
     "properties": { 
      "runbookType": "Script", 
      "logVerbose": false, 
      "logProgress": false 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/Azure'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_Azure_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/Azure.Storage'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_Azure.Storage_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/AzureRM.Automation'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_AzureRM.Automation_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/AzureRM.Compute'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_AzureRM.Compute_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/AzureRM.Profile'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_AzureRM.Profile_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/AzureRM.Resources'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_AzureRM.Resources_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/AzureRM.Sql'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_AzureRM.Sql_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/AzureRM.Storage'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_AzureRM.Storage_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/Microsoft.PowerShell.Core'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_Microsoft.PowerShell.Core_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/Microsoft.PowerShell.Diagnostics'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_Microsoft.PowerShell.Diagnostics_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/Microsoft.PowerShell.Management'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_Microsoft.PowerShell.Management_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/Microsoft.PowerShell.Security'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_Microsoft.PowerShell.Security_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/Microsoft.PowerShell.Utility'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_Microsoft.PowerShell.Utility_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/Microsoft.WSMan.Management'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_Microsoft.WSMan.Management_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    { 
     "comments": "Generalized from resource: '/subscriptions/65b7453f-0c39-4f3f-a113-c0f107f431c4/resourcegroups/Test-Data/providers/Microsoft.Automation/automationAccounts/test3-Automation/modules/Orchestrator.AssetManagement.Cmdlets'.", 
     "type": "Microsoft.Automation/automationAccounts/modules", 
     "name": "[parameters('modules_Orchestrator.AssetManagement.Cmdlets_name')]", 
     "apiVersion": "2015-10-31", 
     "properties": { 
      "isGlobal": true, 
      "version": null, 
      "sizeInBytes": 0 
     }, 
     "resources": [], 
     "dependsOn": [ 
      "[resourceId('Microsoft.Automation/automationAccounts', parameters('automationAccounts_Test2_Automation_name'))]" 
     ] 
    }, 
    {//truncating the rest 

ответ

0

Хорошо, поскольку я соблюдаю то же поведение на нескольких учетных записях, я считаю, что это совершенно нормально. Но у меня нет объяснений этому. Дело в том, что если вы захотите перенести Azure Automation в другую группу ресурсов, все из них тоже будут мигрировать (я недавно тестировал это, просто для удовольствия).
Итог: ожидается.

0

В приведенном выше шаблоне указаны параметры, заданные для заданий, но эти параметры никогда не используются нигде, и шаблон не говорит о фактическом развертывании любых заданий. Предполагая, что шаблон выше - это полный шаблон, вы можете либо удалить эти параметры задания, либо полностью игнорировать их.

Этот шаблон не делает этого, но причина, по которой вам могут потребоваться задания автоматизации в шаблоне ARM, заключается в том, чтобы объявить, что эти задания должны выполняться как часть развертывания шаблона ARM, либо раз в разное развертывание. Поскольку задание (-ы) было бы в шаблоне, вы могли бы даже использовать свойство ресурса dependsOn ресурса, чтобы сказать, что какой-то другой ресурс должен быть развернут только после завершения задания (-ов).

Если вы жестко указываете имя задания, оно будет выполняться только как часть развертывания, если еще нет задания с этим именем в учетной записи автоматизации, в которой задание находится. Если вы укажете имя задания и укажите другое имя неиспользуемого задания в каждом развертывании, задание будет выполняться как часть каждого развертывания.

Работы по автоматизации, по сути, позволяют добавлять к развертываниям ARM-шаблонов императивные шаги и задачи, которые не могут быть связаны с Azure, поскольку задание автоматизации - это просто произвольный код PowerShell.