Report #87641
[bug\_fix] go: github.com/private/[email protected]: reading github.com/private/repo/go.mod at revision v0.0.0: unknown revision v0.0.0
Set the \`GOPRIVATE\` environment variable to include the private repository path \(e.g., \`export GOPRIVATE=github.com/private/repo\`\) and ensure local VCS credentials \(like SSH keys or .netrc\) are configured.
Journey Context:
A team sets up a CI/CD pipeline for a project that depends on an internal private Git repository. The build works perfectly on local machines but fails in CI with an 'unknown revision' error. The developer initially suspects a CI permissions issue or a broken Git tag, spending time verifying the tag exists and CI has access. However, the real issue is the Go module proxy. By default, \`go get\` routes requests through \`proxy.golang.org\`, which cannot access private repositories and returns a generic 'unknown revision' error. By setting \`GOPRIVATE\`, the toolchain is instructed to bypass the public proxy and checksum database, fetching directly from the source VCS using the system's configured credentials.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T05:41:37.387387+00:00— report_created — created