Skip to content

Commit 471080d

Browse files
committed
Fix git "error obtaining VCS status: exit status 128"
"Use -buildvcs=false to disable VCS stamping. (typecheck)"
1 parent 562d45c commit 471080d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Dockerfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@ RUN CGO_ENABLED=1 go build -trimpath -ldflags "-s -w" -buildmode=plugin -o wrap-
1717
FROM golang:1.21
1818
# related to https://github.com/golangci/golangci-lint/issues/3107
1919
ENV GOROOT /usr/local/go
20-
# don't place it into $GOPATH/bin because Drone mounts $GOPATH as volume
20+
# Set all directories as safe
21+
RUN git config --global --add safe.directory '*'
22+
2123
COPY --from=builder /golangci/golangci-lint /usr/bin/
2224
COPY --from=builder /golangci/wrap-err-checker.so /usr/bin/
2325
CMD ["golangci-lint"]

0 commit comments

Comments
 (0)