templates/AWSQuickstart-MSSQL.yml [623:649]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    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\SQLInstall' -Wait -Verbose -Force

           DscStatusCheck
- name: "2NodeInstallSSMS"
  action: aws:runCommand
  onFailure: "step:signalfailure"
  nextStep: "CreateAGBranch"
  inputs:
    DocumentName: AWS-RunPowerShellScript
    InstanceIds: 
      - "{{wsfcNode1InstanceId.InstanceId}}"
      - "{{wsfcNode2InstanceId.InstanceId}}"
    CloudWatchOutputConfig:
      CloudWatchOutputEnabled: "true"
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



templates/sql.template.yaml [1730:1756]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
            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\SQLInstall' -Wait -Verbose -Force
        
                   DscStatusCheck
        - name: "2NodeInstallSSMS"
          action: aws:runCommand
          onFailure: "step:signalfailure"
          nextStep: "CreateAGBranch"
          inputs:
            DocumentName: AWS-RunPowerShellScript
            InstanceIds: 
              - "{{wsfcNode1InstanceId.InstanceId}}"
              - "{{wsfcNode2InstanceId.InstanceId}}"
            CloudWatchOutputConfig:
              CloudWatchOutputEnabled: "true"
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



