templates/AWSQuickstart-MSSQL.yml [819:844]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  action: aws:runCommand
  onFailure: "step:signalfailure"
  nextStep: "AdditionalCreateAGBranch"
  inputs:
    DocumentName: AWS-RunPowerShellScript
    InstanceIds: 
      - "{{wsfcNode1InstanceId.InstanceId}}"
    CloudWatchOutputConfig:
      CloudWatchOutputEnabled: "true"
      CloudWatchLogGroupName: !Ref 'QuickStartLogs'
    Parameters:
      commands: 
        - |     
           function DscStatusCheck () {
               $LCMState = (Get-DscLocalConfigurationManager).LCMState
               if ($LCMState -eq 'PendingConfiguration' -Or $LCMState -eq 'PendingReboot') {
                   'returning 3010, should continue after reboot'
                   exit 3010
               } else {
                 'Completed'
               }
           }
           
           Start-DscConfiguration 'C:\AWSQuickstart\AddAG' -Wait -Verbose -Force

           DscStatusCheck
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



templates/AWSQuickstart-MSSQL.yml [901:926]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  action: aws:runCommand
  onFailure: "step:signalfailure"
  nextStep: "AdditionalCreateAGBranch"
  inputs:
    DocumentName: AWS-RunPowerShellScript
    InstanceIds: 
      - "{{wsfcNode1InstanceId.InstanceId}}"
    CloudWatchOutputConfig:
      CloudWatchOutputEnabled: "true"
      CloudWatchLogGroupName: !Ref 'QuickStartLogs'
    Parameters:
      commands: 
        - |     
           function DscStatusCheck () {
               $LCMState = (Get-DscLocalConfigurationManager).LCMState
               if ($LCMState -eq 'PendingConfiguration' -Or $LCMState -eq 'PendingReboot') {
                   'returning 3010, should continue after reboot'
                   exit 3010
               } else {
                 'Completed'
               }
           }
           
           Start-DscConfiguration 'C:\AWSQuickstart\AddAG' -Wait -Verbose -Force

           DscStatusCheck
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



