fix(ruby): use default credential chain for token generation (#679) #52
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Java Spring Boot integration tests | |
| permissions: { } | |
| on: | |
| workflow_call: {} | |
| workflow_dispatch: | |
| push: | |
| branches: [ main ] | |
| jobs: | |
| create-cluster: | |
| uses: ./.github/workflows/dsql-cluster-create.yml | |
| with: | |
| workflow_name: java-spring-boot | |
| secrets: | |
| AWS_IAM_ROLE: ${{ secrets.JAVA_IAM_ROLE }} | |
| permissions: | |
| id-token: write # required by aws-actions/configure-aws-credentials | |
| test-gradle: | |
| needs: create-cluster | |
| runs-on: ubuntu-latest | |
| permissions: | |
| id-token: write # required by aws-actions/configure-aws-credentials | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Set up JDK 17 | |
| uses: actions/setup-java@v5 | |
| with: | |
| java-version: "17" | |
| distribution: "corretto" | |
| architecture: x64 | |
| cache: gradle | |
| - name: Configure AWS Credentials | |
| uses: aws-actions/configure-aws-credentials@v6 | |
| with: | |
| role-to-assume: ${{ secrets.JAVA_IAM_ROLE }} | |
| aws-region: ${{ needs.create-cluster.outputs.region }} | |
| - name: Run Gradle integration test | |
| working-directory: ./java/spring_boot | |
| env: | |
| CLUSTER_USER: admin | |
| CLUSTER_ENDPOINT: ${{ needs.create-cluster.outputs.cluster-endpoint }} | |
| REGION: ${{ needs.create-cluster.outputs.region }} | |
| EXIT_AFTER_TEST: true | |
| run: ./gradlew bootRun | |
| delete-cluster: | |
| if: always() && needs.create-cluster.result == 'success' | |
| needs: [create-cluster, test-gradle] | |
| uses: ./.github/workflows/dsql-cluster-delete.yml | |
| with: | |
| cluster-id: ${{ needs.create-cluster.outputs.cluster-id }} | |
| region: ${{ needs.create-cluster.outputs.region }} | |
| secrets: | |
| AWS_IAM_ROLE: ${{ secrets.JAVA_IAM_ROLE }} | |
| permissions: | |
| id-token: write # required by aws-actions/configure-aws-credentials |