Skip to content

Conversation

@zhihonl
Copy link
Contributor

@zhihonl zhihonl commented Dec 30, 2025

Description of the issue

The GitHub Actions workflows use inconsistent patterns for handling workflow inputs. Some workflows directly interpolate ${{ inputs.* }} values in shell commands, while others use the recommended env: block pattern. This inconsistency makes the codebase harder to maintain and doesn't follow GitHub Actions best practices.

Description of changes

Standardized input handling across 9 workflow files to use the env: block pattern:

Workflow File Changes
test-artifacts.yml Moved inputs.test_repo_branch and inputs.build_id to env variables
integration-test.yml Moved inputs.build_sha to env variable
application-signals-e2e-test.yml Moved inputs.build_sha to env variable
release-candidate-test.yml Moved inputs.test_repo_branch to env variable
repackage-release-artifacts.yml Moved inputs.build_id to env variable across 4 steps
upload-dependencies.yml Moved inputs.s3_integration_bucket and inputs.github_sha to env variables
eks-performance-cluster-addon-install.yml Moved multiple inputs to env variables in helm and git clone steps
wd-integration-test.yml Moved inputs.build_sha to env variable
test-build.yml Moved inputs.Bucket and inputs.BucketKey to env variables

The pattern change:

# Before
- run: |
    echo "${{ inputs.value }}"

# After  
- env:
    VALUE: ${{ inputs.value }}
  run: |
    echo "$VALUE"

License

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Tests

  1. https://github.com/aws/amazon-cloudwatch-agent/actions/runs/20602789874
  2. https://github.com/aws/amazon-cloudwatch-agent/actions/runs/20603161281
  3. https://github.com/aws/amazon-cloudwatch-agent/actions/runs/20603161294
  4. https://github.com/aws/amazon-cloudwatch-agent/actions/runs/20603162022
  5. https://github.com/aws/amazon-cloudwatch-agent/actions/runs/20603161535

Requirements

Before commiting your code, please do the following steps.

  1. Run make fmt and make fmt-sh
  2. Run make lint

Integration Tests

To run integration tests against this PR, add the ready for testing label.

@zhihonl zhihonl requested a review from a team as a code owner December 30, 2025 16:02
@zhihonl zhihonl added the ready for testing Indicates this PR is ready for integration tests to run label Dec 30, 2025
@zhihonl zhihonl merged commit 66312a7 into main Jan 2, 2026
857 of 1333 checks passed
@zhihonl zhihonl deleted the fix-workflow branch January 2, 2026 17:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready for testing Indicates this PR is ready for integration tests to run

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants