Skip to content

RTECO-945 - Fix Go version mismatch in Alpine APK CI#3592

Merged
jfrog-pipelie-intg merged 1 commit into
masterfrom
RTECO-alpine-go-fix
Jul 8, 2026
Merged

RTECO-945 - Fix Go version mismatch in Alpine APK CI#3592
jfrog-pipelie-intg merged 1 commit into
masterfrom
RTECO-alpine-go-fix

Conversation

@naveenku-jfrog

@naveenku-jfrog naveenku-jfrog commented Jul 8, 2026

Copy link
Copy Markdown
Collaborator

Alpine package repos only ship Go <=1.23 (even on Alpine 3.21), but go.mod requires go 1.26.3, causing 'invalid go version' parse errors.

Fix: do not install Go via 'apk add go'. Instead:

  • Record the host GOROOT after install-go-with-cache (new step)

  • Mount that directory into the Alpine chroot via jirutka/setup-alpine volumes input so the same Go 1.26 binary is available inside Alpine

  • Export GOROOT/GOPATH/GOCACHE into the alpine.sh test step and prepend GOROOT/bin to PATH so 'go' resolves to the host toolchain

  • All tests have passed. If this feature is not already covered by the tests, new tests have been added.

  • The pull request is targeting the master branch.

  • The code has been validated to compile successfully by running go vet ./....

  • The code has been formatted properly using go fmt ./....


Alpine package repos only ship Go <=1.23 (even on Alpine 3.21), but
go.mod requires go 1.26.3, causing 'invalid go version' parse errors.

Fix: do not install Go via 'apk add go'. Instead:
- Record the host GOROOT after install-go-with-cache (new step)
- Mount that directory into the Alpine chroot via jirutka/setup-alpine
  volumes input so the same Go 1.26 binary is available inside Alpine
- Export GOROOT/GOPATH/GOCACHE into the alpine.sh test step and
  prepend GOROOT/bin to PATH so 'go' resolves to the host toolchain

Co-authored-by: Cursor <cursoragent@cursor.com>
@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

👍 Frogbot scanned this pull request and did not find any new security issues.


@attiasas attiasas left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@naveenku-jfrog
naveenku-jfrog enabled auto-merge (squash) July 8, 2026 09:06
@naveenku-jfrog
naveenku-jfrog disabled auto-merge July 8, 2026 09:23
@jfrog-pipelie-intg
jfrog-pipelie-intg merged commit 744d944 into master Jul 8, 2026
99 of 104 checks passed
@jfrog-pipelie-intg
jfrog-pipelie-intg deleted the RTECO-alpine-go-fix branch July 8, 2026 09:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants