Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 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
27 changes: 25 additions & 2 deletions .github/workflows/python-ec2-canary.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ permissions:
contents: read

jobs:
default:
github:
strategy:
fail-fast: false
matrix:
Expand All @@ -28,4 +28,27 @@ jobs:
secrets: inherit
with:
aws-region: ${{ matrix.aws-region }}
caller-workflow-name: 'appsignals-python-e2e-ec2-canary-test'
caller-workflow-name: 'appsignals-python-e2e-ec2-canary-test'
staging-wheel-name: 'aws_opentelemetry_distro-0.3.0-py3-none-any.whl'

asg:
strategy:
fail-fast: false
matrix:
aws-region: [ 'af-south-1','ap-east-1','ap-northeast-1','ap-northeast-2','ap-northeast-3','ap-south-1','ap-south-2','ap-southeast-1',
'ap-southeast-2','ap-southeast-3','ap-southeast-4','ca-central-1','eu-central-1','eu-central-2','eu-north-1',
'eu-south-1','eu-south-2','eu-west-1','eu-west-2','eu-west-3','il-central-1','me-central-1','me-south-1', 'sa-east-1',
'us-east-1','us-east-2', 'us-west-1', 'us-west-2' ]
uses: ./.github/workflows/python-ec2-asg-retry.yml
secrets: inherit
with:
aws-region: ${{ matrix.aws-region }}
caller-workflow-name: 'appsignals-python-e2e-ec2-asg-canary-test'

pypi:
uses: ./.github/workflows/python-ec2-default-retry.yml
secrets: inherit
with:
aws-region: 'us-east-1'
caller-workflow-name: 'appsignals-python-e2e-ec2-pypi-canary-test'
otel-source: 'pypi'
12 changes: 12 additions & 0 deletions .github/workflows/python-ec2-default-retry.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,14 @@ on:
caller-workflow-name:
required: true
type: string
staging-wheel-name:
required: false
default: 'aws-opentelemetry-distro'
type: string
otel-source:
required: false
type: string
default: 'github'

permissions:
id-token: write
Expand All @@ -26,6 +34,8 @@ jobs:
with:
aws-region: ${{ inputs.aws-region }}
caller-workflow-name: ${{ inputs.caller-workflow-name }}
staging-wheel-name: ${{ inputs.staging-wheel-name }}
otel-source: ${{ inputs.otel-source }}

python-ec2-default-attempt-2:
needs: [ python-ec2-default-attempt-1 ]
Expand All @@ -35,6 +45,8 @@ jobs:
with:
aws-region: ${{ inputs.aws-region }}
caller-workflow-name: ${{ inputs.caller-workflow-name }}
staging-wheel-name: ${{ inputs.staging-wheel-name }}
otel-source: ${{ inputs.otel-source }}

publish-metric-attempt-1:
needs: [ python-ec2-default-attempt-1, python-ec2-default-attempt-2 ]
Expand Down
11 changes: 9 additions & 2 deletions .github/workflows/python-ec2-default-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ on:
required: false
default: 'aws-opentelemetry-distro'
type: string
otel-source:
required: false
type: string
default: 'github'
outputs:
job-started:
value: ${{ jobs.python-ec2-default.outputs.job-started }}
Expand All @@ -32,6 +36,7 @@ env:
E2E_TEST_AWS_REGION: ${{ inputs.aws-region }}
CALLER_WORKFLOW_NAME: ${{ inputs.caller-workflow-name }}
ADOT_WHEEL_NAME: ${{ inputs.staging-wheel-name }}
OTEL_SOURCE: ${{ inputs.otel-source }}
SAMPLE_APP_ZIP: s3://aws-appsignals-sample-app-prod-${{ inputs.aws-region }}/python-sample-app.zip
E2E_TEST_ACCOUNT_ID: ${{ secrets.APPLICATION_SIGNALS_E2E_TEST_ACCOUNT_ID }}
E2E_TEST_ROLE_NAME: ${{ secrets.APPLICATION_SIGNALS_E2E_TEST_ROLE_NAME }}
Expand Down Expand Up @@ -70,7 +75,7 @@ jobs:
sleep_time: 60

- name: Generate testing id
run: echo TESTING_ID="${{ github.job }}-${{ github.run_id }}-${{ github.run_number }}-${{ github.run_attempt }}" >> $GITHUB_ENV
run: echo TESTING_ID="${{ github.run_id }}-${{ github.run_number }}-${RANDOM}" >> $GITHUB_ENV

- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v4
Expand All @@ -96,8 +101,10 @@ jobs:
if [ "${{ github.event.repository.name }}" = "aws-otel-python-instrumentation" ]; then
# Reusing the adot-main-build-staging-jar bucket to store the python wheel file
echo GET_ADOT_WHEEL_COMMAND="aws s3 cp s3://adot-main-build-staging-jar/${{ env.ADOT_WHEEL_NAME }} ./${{ env.ADOT_WHEEL_NAME }} && python3.9 -m pip install ${{ env.ADOT_WHEEL_NAME }}" >> $GITHUB_ENV
else
elif [ "${{ env.OTEL_SOURCE }}" == "pypi" ]; then
echo GET_ADOT_WHEEL_COMMAND="python3.9 -m pip install ${{ env.ADOT_WHEEL_NAME }}" >> $GITHUB_ENV
else
echo GET_ADOT_WHEEL_COMMAND="wget -O ${{ env.ADOT_WHEEL_NAME }} https://github.com/aws-observability/aws-otel-python-instrumentation/releases/latest/download/${{ env.ADOT_WHEEL_NAME }} && python3.9 -m pip install ${{ env.ADOT_WHEEL_NAME }}" >> $GITHUB_ENV
fi

- name: Set Get CW Agent command environment variable
Expand Down