Skip to content

Commit

Permalink
Only run operator test
Browse files Browse the repository at this point in the history
  • Loading branch information
majanjua-amzn committed Jul 15, 2024
1 parent d6f540b commit 28e4faa
Show file tree
Hide file tree
Showing 2 changed files with 263 additions and 262 deletions.
123 changes: 62 additions & 61 deletions .github/workflows/e2e-tests-with-operator.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,51 +31,51 @@ permissions:

jobs:
# job to build testbatches for e2e integration test
build-sample-app:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: actions/setup-java@v4
with:
java-version: 17
distribution: temurin

# cache local patch outputs
- name: Cache local Maven repository
id: cache-local-maven-repo
uses: actions/cache@v3
with:
path: |
~/.m2/repository/io/opentelemetry/
key: ${{ runner.os }}-maven-local-${{ hashFiles('.github/patches/opentelemetry-java*.patch') }}

- name: Publish patched dependencies to maven local
uses: ./.github/actions/patch-dependencies
if: steps.cache-local-maven-repo.outputs.cache-hit != 'true'
with:
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
gpg_password: ${{ secrets.GPG_PASSPHRASE }}

- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_ARN }}
aws-region: ${{ env.AWS_DEFAULT_REGION }}

- name: Log in to AWS ECR
uses: docker/login-action@v3
with:
registry: public.ecr.aws

- name: Build and push Sample-Apps without Auto-Instrumentation Agent
uses: gradle/gradle-build-action@v3
with:
arguments: jibBuildWithoutAgent
env:
COMMIT_HASH: ${{ inputs.image_tag }}
# build-sample-app:
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v4
# with:
# fetch-depth: 0

# - uses: actions/setup-java@v4
# with:
# java-version: 17
# distribution: temurin

# # cache local patch outputs
# - name: Cache local Maven repository
# id: cache-local-maven-repo
# uses: actions/cache@v3
# with:
# path: |
# ~/.m2/repository/io/opentelemetry/
# key: ${{ runner.os }}-maven-local-${{ hashFiles('.github/patches/opentelemetry-java*.patch') }}

# - name: Publish patched dependencies to maven local
# uses: ./.github/actions/patch-dependencies
# if: steps.cache-local-maven-repo.outputs.cache-hit != 'true'
# with:
# gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
# gpg_password: ${{ secrets.GPG_PASSPHRASE }}

# - name: Configure AWS Credentials
# uses: aws-actions/configure-aws-credentials@v4
# with:
# role-to-assume: ${{ secrets.AWS_ASSUME_ROLE_ARN }}
# aws-region: ${{ env.AWS_DEFAULT_REGION }}

# - name: Log in to AWS ECR
# uses: docker/login-action@v3
# with:
# registry: public.ecr.aws

# - name: Build and push Sample-Apps without Auto-Instrumentation Agent
# uses: gradle/gradle-build-action@v3
# with:
# arguments: jibBuildWithoutAgent
# env:
# COMMIT_HASH: ${{ inputs.image_tag }}

get-testing-suites:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -118,7 +118,8 @@ jobs:
# job to run the e2e integration tests
run-batch-job:
runs-on: ubuntu-latest
needs: [ build-sample-app, get-testing-suites ]
# needs: [ build-sample-app, get-testing-suites ]
needs: [ get-testing-suites ]
strategy:
fail-fast: false
matrix: ${{ fromJson(needs.get-testing-suites.outputs.test-case-batch-key) }}
Expand Down Expand Up @@ -147,8 +148,8 @@ jobs:
with:
role-to-assume: ${{ secrets.TEMP_JAVA_INSTRUMENTATION_INTEG_TEST_ARN }}
aws-region: us-west-2
# 4 hours
role-duration-seconds: 14400
# 1 hours
role-duration-seconds: 3600

- name: Checkout Testing Framework repository
uses: actions/checkout@v4
Expand Down Expand Up @@ -197,16 +198,16 @@ jobs:
make terraformCleanup
# publish status
publish-build-status:
needs: [ run-batch-job ]
if: ${{ always() }}
uses: ./.github/workflows/publish-status.yml
with:
namespace: 'ADOT/GitHubActions'
repository: ${{ github.repository }}
branch: ${{ github.ref_name }}
workflow: ${{ inputs.caller-workflow-name }}
success: ${{ needs.run-batch-job.result == 'success' }}
region: us-west-2
secrets:
roleArn: ${{ secrets.METRICS_ROLE_ARN }}
# publish-build-status:
# needs: [ run-batch-job ]
# if: ${{ always() }}
# uses: ./.github/workflows/publish-status.yml
# with:
# namespace: 'ADOT/GitHubActions'
# repository: ${{ github.repository }}
# branch: ${{ github.ref_name }}
# workflow: ${{ inputs.caller-workflow-name }}
# success: ${{ needs.run-batch-job.result == 'success' }}
# region: us-west-2
# secrets:
# roleArn: ${{ secrets.METRICS_ROLE_ARN }}
Loading

0 comments on commit 28e4faa

Please sign in to comment.