Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/ec2-integration-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ on:
type: string
is_selinux_test:
type: boolean
is_onprem_test:
type: boolean
s3_integration_bucket:
type: string
secrets:
Expand Down Expand Up @@ -123,6 +125,7 @@ jobs:
-var="ssh_key_value=${{env.PRIVATE_KEY}}" \
-var="test_dir=${{ matrix.arrays.test_dir }}" \
-var="test_name=${{ matrix.arrays.os }}" \
-var="is_onprem=${{ inputs.is_onprem_test }}" \
-var="user=${{ matrix.arrays.username }}"; then
terraform destroy -var="region=${{ inputs.region }}" -var="ami=${{ matrix.arrays.ami }}" -auto-approve
else
Expand Down
24 changes: 24 additions & 0 deletions .github/workflows/test-artifacts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@
outputs:
ec2_gpu_matrix: ${{ steps.set-matrix.outputs.ec2_gpu_matrix }}
ec2_linux_matrix: ${{ steps.set-matrix.outputs.ec2_linux_matrix }}
ec2_linux_onprem_matrix: ${{ steps.set-matrix.outputs.ec2_linux_onprem_matrix }}
ec2_selinux_matrix: ${{ steps.set-matrix.outputs.ec2_selinux_matrix }}
ec2_windows_matrix: ${{ steps.set-matrix.outputs.ec2_windows_matrix }}
ec2_mac_matrix: ${{ steps.set-matrix.outputs.ec2_mac_matrix }}
Expand Down Expand Up @@ -163,6 +164,7 @@
echo "ec2_gpu_matrix=$(echo $(cat generator/resources/ec2_gpu_complete_test_matrix.json))" >> "$GITHUB_OUTPUT"
echo "eks_addon_matrix=$(echo $(cat generator/resources/eks_addon_complete_test_matrix.json))" >> "$GITHUB_OUTPUT"
echo "ec2_linux_matrix=$(echo $(cat generator/resources/ec2_linux_complete_test_matrix.json))" >> "$GITHUB_OUTPUT"
echo "ec2_linux_onprem_matrix=$(echo $(cat generator/resources/ec2_linux_onprem_complete_test_matrix.json))" >> "$GITHUB_OUTPUT"
echo "ec2_selinux_matrix=$(echo $(cat generator/resources/ec2_selinux_complete_test_matrix.json))" >> "$GITHUB_OUTPUT"
echo "ec2_windows_matrix=$(echo $(cat generator/resources/ec2_windows_complete_test_matrix.json))" >> "$GITHUB_OUTPUT"
echo "ec2_mac_matrix=$(echo $(cat generator/resources/ec2_mac_complete_test_matrix.json))" >> "$GITHUB_OUTPUT"
Expand All @@ -182,6 +184,7 @@
echo "ec2_gpu_matrix: ${{ steps.set-matrix.outputs.ec2_gpu_matrix }}"
echo "eks_addon_matrix: ${{ steps.set-matrix.outputs.eks_addon_matrix }}"
echo "ec2_linux_matrix: ${{ steps.set-matrix.outputs.ec2_linux_matrix }}"
echo "ec2_linux_onprem_matrix: ${{ steps.set-matrix.outputs.ec2_linux_onprem_matrix }}"
echo "ec2_selinux_matrix: ${{ steps.set-matrix.outputs.ec2_selinux_matrix }}"
echo "ec2_windows_matrix: ${{ steps.set-matrix.outputs.ec2_windows_matrix }}"
echo "ec2_mac_matrix: ${{ steps.set-matrix.outputs.ec2_mac_matrix }}"
Expand Down Expand Up @@ -435,10 +438,31 @@
terraform_assume_role: ${{ vars.TERRAFORM_AWS_ASSUME_ROLE }}
s3_integration_bucket: ${{ vars.S3_INTEGRATION_BUCKET }}
is_selinux_test: false
is_onprem_test: false
secrets: inherit

LinuxOnPremIntegrationTest:
needs: [GenerateTestMatrix, OutputEnvVariables]
name: 'OnpremLinux'
uses: ./.github/workflows/ec2-integration-test.yml
with:
build_id: ${{ inputs.build_id }}
test_dir: terraform/ec2/linux
job_id: linux-onprem-integration-test
test_props: ${{needs.GenerateTestMatrix.outputs.ec2_linux_onprem_matrix}}
test_repo_name: ${{ needs.OutputEnvVariables.outputs.CWA_GITHUB_TEST_REPO_NAME }}
test_repo_url: ${{ needs.OutputEnvVariables.outputs.CWA_GITHUB_TEST_REPO_URL }}
test_repo_branch: ${{ needs.OutputEnvVariables.outputs.CWA_GITHUB_TEST_REPO_BRANCH }}
localstack_host: ${{needs.StartLocalStack.outputs.local_stack_host_name}}
region: us-west-2
terraform_assume_role: ${{ vars.TERRAFORM_AWS_ASSUME_ROLE }}
s3_integration_bucket: ${{ vars.S3_INTEGRATION_BUCKET }}
is_selinux_test: false
is_onprem_test: true
secrets: inherit


EC2LinuxIntegrationTestITAR:

Check warning

Code scanning / CodeQL

Workflow does not contain permissions Medium test

Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {}
needs: [ StartLocalStackITAR, GenerateTestMatrix, OutputEnvVariables ]
name: 'EC2LinuxITAR'
uses: ./.github/workflows/ec2-integration-test.yml
Expand Down
Loading