Skip to content

Add workflow to hydrate Go module proxy on push/tag#2118

Merged
okankoAMZ merged 6 commits into
mainfrom
add-hydrate-goproxy-workflow
May 21, 2026
Merged

Add workflow to hydrate Go module proxy on push/tag#2118
okankoAMZ merged 6 commits into
mainfrom
add-hydrate-goproxy-workflow

Conversation

@okankoAMZ
Copy link
Copy Markdown
Contributor

Ensures github.com/aws/amazon-cloudwatch-agent is immediately available on proxy.golang.org after commits to the main branch or on tag releases.

Description of the issue

Currently, there is no automated process to ensure that the amazon-cloudwatch-agent module is updated on proxy.golang.org after changes are pushed to the main branch or when new tags are released. This can cause delays in module availability for users relying on proxy.golang.org for dependency management.

Description of changes

This PR adds a GitHub Actions workflow file .github/workflows/hydrate-goproxy.yaml to automate the process of ensuring proxy.golang.org has the latest version of the amazon-cloudwatch-agent module. The workflow runs under the following conditions:

  1. On pushes to the main branch
  2. On new tag releases.
  3. Manually triggered via workflow dispatch.

The workflow job performs the following steps:

  • Initializes a Go module named hydrate-goproxy.
  • Fetches the correct version of the amazon-cloudwatch-agent module from the current commit SHA or tag.

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

  • Validation of the workflow syntax.
  • Manual runs via workflow_dispatch to ensure correct behavior for both tag references and SHA.

Requirements

Before committing 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.
Action:
https://github.com/aws/amazon-cloudwatch-agent/actions/runs/25747937491/job/75616171748

go: creating new go.mod: module hydrate-goproxy
go: downloading github.com/aws/amazon-cloudwatch-agent v1.300067.1-0.20260512162747-8ee76dbf4fb9
go: github.com/aws/amazon-cloudwatch-agent@v1.300067.1-0.20260512162747-8ee76dbf4fb9 requires go >= 1.25.8; switching to go1.25.10
go: downloading go1.25.10 (linux/amd64)
go: upgraded go 1.24.13 => 1.25.8
go: added github.com/aws/amazon-cloudwatch-agent v1.300067.1-0.20260512162747-8ee76dbf4fb9

Verification:

> go list -m github.com/aws/amazon-cloudwatch-agent@8ee76dbf4fb9

github.com/aws/amazon-cloudwatch-agent v1.300067.1-0.20260512162747-8ee76dbf4fb9

okankoAMZ and others added 2 commits May 12, 2026 16:27
Ensures github.com/aws/amazon-cloudwatch-agent is immediately available
on proxy.golang.org after commits to main or tag releases.
@okankoAMZ okankoAMZ marked this pull request as ready for review May 12, 2026 18:52
@okankoAMZ okankoAMZ requested a review from a team as a code owner May 12, 2026 18:52
Comment thread .github/workflows/hydrate-goproxy.yaml Fixed
TravisStark
TravisStark previously approved these changes May 12, 2026
…ntain permissions'

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
@okankoAMZ okankoAMZ merged commit 92c3613 into main May 21, 2026
25 checks passed
@okankoAMZ okankoAMZ deleted the add-hydrate-goproxy-workflow branch May 21, 2026 18:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants