Skip to content

Commit

Permalink
Mk/Uses/go.mk: Revert part of 4e29133
Browse files Browse the repository at this point in the history
Revert module cache revalidation in post-fetch (`go mod verify`), it
breaks non-root poudriere builds.

`go mod verify` needs read/write access to the GOMODCACHE and because
extract stage runs fetch stage again but under a restricted user, `go
mod verify` fails with a "permission denied" error.
  • Loading branch information
dmgk committed May 7, 2022
1 parent 0a2f0da commit ef7fee4
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions Mk/Uses/go.mk
Expand Up @@ -166,8 +166,7 @@ post-fetch:
@${ECHO_MSG} "===> Fetching ${GO_MODNAME} dependencies";
@(cd ${DISTDIR}/${DIST_SUBDIR}; \
[ -e go.mod ] || ${RLN} ${GO_MODFILE} go.mod; \
${SETENV} ${GO_ENV} GOPROXY=${GO_GOPROXY} ${GO_CMD} mod download -x; \
${SETENV} ${GO_ENV} GOPROXY=${GO_GOPROXY} ${GO_CMD} mod verify)
${SETENV} ${GO_ENV} GOPROXY=${GO_GOPROXY} ${GO_CMD} mod download -x)
. endif

. if !target(post-extract)
Expand Down

0 comments on commit ef7fee4

Please sign in to comment.