Register-AzAutomationDscNode "-AsJob"
Description of the new feature
Ability to submit Register-AzAutomationDscNode as a job since this can be time consuming
Proposed implementation details (optional)
Similar to creating VMs via New-AzVm -AsJob, it would be cool if there was a flag to submit Register-AzAutomationDscNode as a job so scripts could continue on.
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @zjalexander
This is triaged and currently in the backlog, will consider it if resourcing allows.
Unfortunately because of other priorities we were not able to pick this up, please expect an update in Q4CY20.
Currently, team is busy with other high priority items and this would be picked up in CY2021 Q2.
@jzuchora87 Apologies for the late reply. We will provide an update on this github thread soon.
@vikram-m Could you please provide an update on this issue ? Awaiting you reply.
Hi, we're sending this friendly reminder because we haven't heard back from you in a while. We need more information about this issue to help address it. Please be sure to give us your input within the next 7 days. If we don't hear back from you within 14 days of this comment the issue will be automatically closed. Thank you!
Hi! We do have the same issue. Register-AzAutomationDscNode task take more than 40 minutes when is executed via Azure pipeline. That means that blocks the rest of the jobs/tasks until this is complete.
The same registration DSC Node process, does not take that amount of time via Azure portal or even cloud shell...I assume that is because it keeps working in background.
It would be a good feature if the option "-AsJob" could be an optional parameter to be executed in background as well, during pipeline tasks.
This is the command that we are using:
- task: AzurePowerShell@5
enabled: true
displayName: 'Register Node'
name: 'register_node'
inputs:
azureSubscription: ${{ parameters.serviceConnectionName }}
azurePowerShellVersion: 'latestVersion' # Required. Options: latestVersion, otherVersion
scriptType: inlineScript
Inline: |
Register-AzAutomationDscNode -AutomationAccountName "Contoso17" -AzureVMName "VirtualMachine01" -ResourceGroupName "ResourceGroup01"-NodeConfigurationName "ContosoConfiguration.webserver" -AsJob
And this is the error, after adding -AsJob:
##[error]A parameter cannot be found that matches parameter name 'AsJob'.
##[error]PowerShell exited with code '1'.
Thanks!