@@ -130,10 +130,12 @@ jobs:
130130    runs-on : ubuntu-latest 
131131    outputs :
132132      ec2_gpu_matrix : ${{ steps.set-matrix.outputs.ec2_gpu_matrix }} 
133-       ec2_linux_nvidia_matrix : ${{ steps.set-matrix.outputs.ec2_linux_nvidia_matrix }} 
133+       ec2_linux_wd_matrix : ${{ steps.set-matrix.outputs.ec2_linux_wd_matrix }} 
134+       ec2_linux_wd_nvidia_matrix : ${{ steps.set-matrix.outputs.ec2_linux_wd_nvidia_matrix }} 
134135      ec2_linux_matrix : ${{ steps.set-matrix.outputs.ec2_linux_matrix }} 
135136      ec2_selinux_matrix : ${{ steps.set-matrix.outputs.ec2_selinux_matrix }} 
136-       ec2_windows_nvidia_matrix : ${{ steps.set-matrix.outputs.ec2_windows_nvidia_matrix }} 
137+       ec2_windows_wd_matrix : ${{ steps.set-matrix.outputs.ec2_windows_wd_matrix }} 
138+       ec2_windows_wd_nvidia_matrix : ${{ steps.set-matrix.outputs.ec2_windows_wd_nvidia_matrix }} 
137139      ec2_windows_matrix : ${{ steps.set-matrix.outputs.ec2_windows_matrix }} 
138140      ec2_mac_matrix : ${{ steps.set-matrix.outputs.ec2_mac_matrix }} 
139141      ec2_performance_matrix : ${{steps.set-matrix.outputs.ec2_performance_matrix}} 
@@ -164,10 +166,12 @@ jobs:
164166          go run --tags=generator generator/test_case_generator.go 
165167          echo "ec2_gpu_matrix=$(echo $(cat generator/resources/ec2_gpu_complete_test_matrix.json))" >> "$GITHUB_OUTPUT" 
166168          echo "eks_addon_matrix=$(echo $(cat generator/resources/eks_addon_complete_test_matrix.json))" >> "$GITHUB_OUTPUT" 
167-           echo "ec2_linux_nvidia_matrix=$(echo $(cat generator/resources/ec2_linux_nvidia_complete_test_matrix.json))" >> "$GITHUB_OUTPUT" 
169+           echo "ec2_linux_wd_matrix=$(echo $(cat generator/resources/ec2_linux_wd_complete_test_matrix.json))" >> "$GITHUB_OUTPUT" 
170+           echo "ec2_linux_wd_nvidia_matrix=$(echo $(cat generator/resources/ec2_linux_wd_nvidia_complete_test_matrix.json))" >> "$GITHUB_OUTPUT" 
168171          echo "ec2_linux_matrix=$(echo $(cat generator/resources/ec2_linux_complete_test_matrix.json))" >> "$GITHUB_OUTPUT" 
169172          echo "ec2_selinux_matrix=$(echo $(cat generator/resources/ec2_selinux_complete_test_matrix.json))" >> "$GITHUB_OUTPUT" 
170-           echo "ec2_windows_nvidia_matrix=$(echo $(cat generator/resources/ec2_windows_nvidia_complete_test_matrix.json))" >> "$GITHUB_OUTPUT" 
173+           echo "ec2_windows_wd_matrix=$(echo $(cat generator/resources/ec2_windows_wd_complete_test_matrix.json))" >> "$GITHUB_OUTPUT" 
174+           echo "ec2_windows_wd_nvidia_matrix=$(echo $(cat generator/resources/ec2_windows_wd_nvidia_complete_test_matrix.json))" >> "$GITHUB_OUTPUT" 
171175          echo "ec2_windows_matrix=$(echo $(cat generator/resources/ec2_windows_complete_test_matrix.json))" >> "$GITHUB_OUTPUT" 
172176          echo "ec2_mac_matrix=$(echo $(cat generator/resources/ec2_mac_complete_test_matrix.json))" >> "$GITHUB_OUTPUT" 
173177          echo "ec2_performance_matrix=$(echo $(cat generator/resources/ec2_performance_complete_test_matrix.json))" >> "$GITHUB_OUTPUT" 
@@ -185,10 +189,10 @@ jobs:
185189        run : | 
186190          echo "ec2_gpu_matrix: ${{ steps.set-matrix.outputs.ec2_gpu_matrix }}" 
187191          echo "eks_addon_matrix: ${{ steps.set-matrix.outputs.eks_addon_matrix }}" 
188-           echo "ec2_linux_nvidia_matrix : ${{ steps.set-matrix.outputs.ec2_linux_nvidia_matrix  }}" 
192+           echo "ec2_linux_wd_nvidia_matrix : ${{ steps.set-matrix.outputs.ec2_linux_wd_nvidia_matrix  }}" 
189193          echo "ec2_linux_matrix: ${{ steps.set-matrix.outputs.ec2_linux_matrix }}" 
190194          echo "ec2_selinux_matrix: ${{ steps.set-matrix.outputs.ec2_selinux_matrix }}" 
191-           echo "ec2_windows_nvidia_matrix : ${{ steps.set-matrix.outputs.ec2_windows_nvidia_matrix  }}" 
195+           echo "ec2_windows_wd_nvidia_matrix : ${{ steps.set-matrix.outputs.ec2_windows_wd_nvidia_matrix  }}" 
192196          echo "ec2_windows_matrix: ${{ steps.set-matrix.outputs.ec2_windows_matrix }}" 
193197          echo "ec2_mac_matrix: ${{ steps.set-matrix.outputs.ec2_mac_matrix }}" 
194198          echo "ec2_performance_matrix: ${{ steps.set-matrix.outputs.ec2_performance_matrix}}" 
@@ -420,14 +424,14 @@ jobs:
420424            fi 
421425            terraform destroy --auto-approve 
422426
423- EC2NvidiaNVIDIALinuxWDIntegrationTest :
427+ EC2LinuxWDIntegrationTest :
424428    needs : [ StartLocalStack, GenerateTestMatrix, OutputEnvVariables ] 
425429    name : ${{matrix.arrays.testName}} 
426430    runs-on : ubuntu-latest 
427431    strategy :
428432      fail-fast : false 
429433      matrix :
430-         arrays : ${{ fromJson(needs.GenerateTestMatrix.outputs.ec2_linux_nvidia_matrix ) }} 
434+         arrays : ${{ fromJson(needs.GenerateTestMatrix.outputs.ec2_linux_wd_matrix ) }} 
431435    permissions :
432436      id-token : write 
433437      contents : read 
@@ -509,14 +513,184 @@ jobs:
509513
510514            terraform destroy -lock-timeout=5m -var="ami=${{ matrix.arrays.ami }}" --auto-approve 
511515
512- EC2NvidiaNVIDIAWindowsWDIntegrationTest :
516+ EC2WindowsWDIntegrationTest :
513517    needs : [ StartLocalStack, GenerateTestMatrix, OutputEnvVariables ] 
514518    name : ${{matrix.arrays.testName}} 
515519    runs-on : ubuntu-latest 
516520    strategy :
517521      fail-fast : false 
518522      matrix :
519-         arrays : ${{ fromJson(needs.GenerateTestMatrix.outputs.ec2_windows_nvidia_matrix) }} 
523+         arrays : ${{ fromJson(needs.GenerateTestMatrix.outputs.ec2_windows_wd_matrix) }} 
524+     permissions :
525+       id-token : write 
526+       contents : read 
527+     steps :
528+       - uses : actions/checkout@v3 
529+         with :
530+           repository : ${{ needs.OutputEnvVariables.outputs.CWA_GITHUB_TEST_REPO_NAME }} 
531+           ref : ${{ needs.OutputEnvVariables.outputs.CWA_GITHUB_TEST_REPO_BRANCH }} 
532+ 
533+       - name : Configure AWS Credentials 
534+         uses : aws-actions/configure-aws-credentials@v4 
535+         with :
536+           role-to-assume : ${{ env.TERRAFORM_AWS_ASSUME_ROLE }} 
537+           aws-region : us-west-2 
538+           role-duration-seconds : ${{ env.TERRAFORM_AWS_ASSUME_ROLE_DURATION }} 
539+ 
540+       - name : Echo Test Info 
541+         run : echo run on ec2 instance os ${{ matrix.arrays.os }} arc ${{ matrix.arrays.arc }} test dir ${{ matrix.arrays.test_dir }} 
542+ 
543+       - name : Install Terraform 
544+         uses : hashicorp/setup-terraform@v3 
545+         with :
546+           terraform_version : 1.12.0 
547+ 
548+       - name : Verify Terraform version 
549+         run : terraform --version 
550+ 
551+       - name : Terraform apply 
552+         uses : nick-fields/retry@v2 
553+         with :
554+           max_attempts : 3 
555+           timeout_minutes : 60 
556+           retry_wait_seconds : 5 
557+           command : | 
558+             if [ "${{ matrix.arrays.terraform_dir }}" != "" ]; then 
559+               cd "${{ matrix.arrays.terraform_dir }}" 
560+             else 
561+               cd terraform/ec2/win 
562+             fi 
563+ 
564+             terraform init 
565+             if terraform apply --auto-approve \ 
566+               -var="github_test_repo_branch=${{ needs.OutputEnvVariables.outputs.CWA_GITHUB_TEST_REPO_BRANCH }}" \ 
567+               -var="ec2_instance_type=${{ matrix.arrays.instanceType }}" \ 
568+               -var="ssh_key_value=${PRIVATE_KEY}" \ 
569+               -var="ssh_key_name=${KEY_NAME}" \ 
570+               -var="test_name=${{ matrix.arrays.os }}" \ 
571+               -var="cwa_github_sha=${{ inputs.build_id }}"  \ 
572+               -var="test_dir=${{ matrix.arrays.test_dir }}" \ 
573+               -var="ami=${{ matrix.arrays.ami }}" \ 
574+               -var="s3_bucket=${S3_INTEGRATION_BUCKET}" ; then 
575+               terraform destroy -auto-approve 
576+             else 
577+               terraform destroy -auto-approve && exit 1 
578+             fi 
579+ 
580+ name : Terraform destroy 
581+         if : ${{ (cancelled() || failure()) }} 
582+         uses : nick-fields/retry@v2 
583+         with :
584+           max_attempts : 3 
585+           timeout_minutes : 8 
586+           retry_wait_seconds : 5 
587+           command : | 
588+             if [ "${{ matrix.arrays.terraform_dir }}" != "" ]; then 
589+               cd "${{ matrix.arrays.terraform_dir }}" 
590+             else 
591+               cd terraform/ec2/win 
592+             fi 
593+ 
594+             terraform destroy -lock-timeout=5m -var="ami=${{ matrix.arrays.ami }}" --auto-approve 
595+ 
596+ 
597+ EC2NvidiaLinuxWDIntegrationTest :
598+     needs : [ StartLocalStack, GenerateTestMatrix, OutputEnvVariables ] 
599+     name : ${{matrix.arrays.testName}} 
600+     runs-on : ubuntu-latest 
601+     strategy :
602+       fail-fast : false 
603+       matrix :
604+         arrays : ${{ fromJson(needs.GenerateTestMatrix.outputs.ec2_linux_wd_nvidia_matrix) }} 
605+     permissions :
606+       id-token : write 
607+       contents : read 
608+     steps :
609+       - uses : actions/checkout@v3 
610+         with :
611+           repository : ${{ needs.OutputEnvVariables.outputs.CWA_GITHUB_TEST_REPO_NAME }} 
612+           ref : ${{ needs.OutputEnvVariables.outputs.CWA_GITHUB_TEST_REPO_BRANCH }} 
613+ 
614+       - name : Configure AWS Credentials 
615+         uses : aws-actions/configure-aws-credentials@v4 
616+         with :
617+           role-to-assume : ${{ env.TERRAFORM_AWS_ASSUME_ROLE }} 
618+           aws-region : us-west-2 
619+           role-duration-seconds : ${{ env.TERRAFORM_AWS_ASSUME_ROLE_DURATION }} 
620+ 
621+       - name : Echo Test Info 
622+         run : echo run on ec2 instance os ${{ matrix.arrays.os }} arc ${{ matrix.arrays.arc }} test dir ${{ matrix.arrays.test_dir }} 
623+ 
624+       - name : Install Terraform 
625+         uses : hashicorp/setup-terraform@v3 
626+         with :
627+           terraform_version : 1.12.0 
628+ 
629+       - name : Verify Terraform version 
630+         run : terraform --version 
631+ 
632+       - name : Terraform apply 
633+         uses : nick-fields/retry@v2 
634+         with :
635+           max_attempts : 3 
636+           timeout_minutes : 30 
637+           retry_wait_seconds : 5 
638+           command : | 
639+             if [ "${{ matrix.arrays.terraform_dir }}" != "" ]; then 
640+               cd "${{ matrix.arrays.terraform_dir }}" 
641+             else 
642+               cd terraform/ec2/linux 
643+             fi 
644+ 
645+             terraform init 
646+             if terraform apply --auto-approve \ 
647+               -var="ssh_key_value=${{env.PRIVATE_KEY}}" \ 
648+               -var="github_test_repo=${{ needs.OutputEnvVariables.outputs.CWA_GITHUB_TEST_REPO_URL }}" \ 
649+               -var="test_name=${{ matrix.arrays.os }}" \ 
650+               -var="cwa_github_sha=${{inputs.build_id}}" \ 
651+               -var="install_agent=${{ matrix.arrays.installAgentCommand }}" \ 
652+               -var="github_test_repo_branch=${{ needs.OutputEnvVariables.outputs.CWA_GITHUB_TEST_REPO_BRANCH }}" \ 
653+               -var="ec2_instance_type=${{ matrix.arrays.instanceType }}" \ 
654+               -var="user=${{ matrix.arrays.username }}" \ 
655+               -var="ami=${{ matrix.arrays.ami }}" \ 
656+               -var="ca_cert_path=${{ matrix.arrays.caCertPath }}" \ 
657+               -var="arc=${{ matrix.arrays.arc }}" \ 
658+               -var="binary_name=${{ matrix.arrays.binaryName }}" \ 
659+               -var="local_stack_host_name=${{ needs.StartLocalStack.outputs.local_stack_host_name }}" \ 
660+               -var="s3_bucket=${{ vars.S3_INTEGRATION_BUCKET }}" \ 
661+               -var="ssh_key_name=${{env.KEY_NAME}}" \ 
662+               -var="test_dir=${{ matrix.arrays.test_dir }}" \ 
663+               -var="agent_start=${{ matrix.arrays.agentStartCommand }}" \ 
664+               -var="excluded_tests='${{ matrix.arrays.excludedTests }}'" \ 
665+               -var="plugin_tests='${{ github.event.inputs.plugins }}'"; then terraform destroy -auto-approve 
666+             else 
667+               terraform destroy -auto-approve && exit 1 
668+             fi 
669+ 
670+ name : Terraform destroy 
671+         if : ${{ (cancelled() || failure()) }} 
672+         uses : nick-fields/retry@v2 
673+         with :
674+           max_attempts : 3 
675+           timeout_minutes : 8 
676+           retry_wait_seconds : 5 
677+           command : | 
678+             if [ "${{ matrix.arrays.terraform_dir }}" != "" ]; then 
679+               cd "${{ matrix.arrays.terraform_dir }}" 
680+             else 
681+               cd terraform/ec2/linux 
682+             fi 
683+ 
684+             terraform destroy -lock-timeout=5m -var="ami=${{ matrix.arrays.ami }}" --auto-approve 
685+ 
686+ EC2NvidiaWindowsWDIntegrationTest :
687+     needs : [ StartLocalStack, GenerateTestMatrix, OutputEnvVariables ] 
688+     name : ${{matrix.arrays.testName}} 
689+     runs-on : ubuntu-latest 
690+     strategy :
691+       fail-fast : false 
692+       matrix :
693+         arrays : ${{ fromJson(needs.GenerateTestMatrix.outputs.ec2_windows_wd_nvidia_matrix) }} 
520694    permissions :
521695      id-token : write 
522696      contents : read 
0 commit comments