-
Notifications
You must be signed in to change notification settings - Fork 206
53 lines (50 loc) · 2.01 KB
/
data-prepper-aws-secrets-e2e-tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# This workflow will build a Java project with Gradle
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle
name: Data Prepper AWS secrets End-to-end test with Gradle
on:
push:
branches: [ main ]
pull_request_target:
types: [ opened, synchronize, reopened ]
workflow_dispatch:
# permission can be added at job level or workflow level
permissions:
id-token: write # This is required for requesting the JWT
contents: read # This is required for actions/checkout
jobs:
build:
strategy:
matrix:
java: [ 11, 17, 21, docker ]
test: [ 'basicLogWithAwsSecretsEndToEndTest' ]
fail-fast: false
runs-on: ubuntu-latest
steps:
- name: Git clone the repository
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: configure aws credentials
id: creds
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: ${{ secrets.TEST_IAM_ROLE_ARN }}
aws-region: ${{ secrets.TEST_REGION }}
output-credentials: true
- name: get caller identity 1
run: |
aws sts get-caller-identity
- name: Configure AWS Credentials file
run: |
aws configure set default.region ${{ secrets.TEST_REGION }}
aws configure set default.aws_access_key_id ${{ steps.creds.outputs.aws-access-key-id }}
aws configure set default.aws_secret_access_key ${{ steps.creds.outputs.aws-secret-access-key }}
aws configure set default.aws_session_token ${{ steps.creds.outputs.aws-session-token }}
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11
- name: Checkout Data Prepper
uses: actions/checkout@v2
- name: Run basic grok with AWS secrets end-to-end tests with Gradle
run: AWS_PROFILE=default ./gradlew -PendToEndJavaVersion=${{ matrix.java }} :e2e-test:log:${{ matrix.test }}