File tree Expand file tree Collapse file tree 3 files changed +10
-1
lines changed
Expand file tree Collapse file tree 3 files changed +10
-1
lines changed Original file line number Diff line number Diff line change 1616 cmds :
1717 - >
1818 GITHUB_REF= dagger -s call -m github.com/sagikazarmark/daggerverse/golangci-lint@${DAGGER_GOLANGCI_LINT_SHA}
19+ with-linter-cache --cache golangci-lint
20+ with-build-cache --cache go-build
21+ with-module-cache --cache go-mod
1922 run --source . --config .golangci.yml stdout
2023 sources :
2124 - ./**/*.go
Original file line number Diff line number Diff line change @@ -16,6 +16,9 @@ COPY ../cmd/manager/main.go cmd/manager/main.go
1616COPY ../api/ api/
1717COPY ../internal/ internal/
1818
19+ ENV GOCACHE=/root/.cache/go-build
20+ ENV GOMODCACHE=/go/pkg/mod
21+
1922# Build
2023# the GOARCH has not a default value to allow the binary be built according to the host where the command
2124# was called. For example, if we call make docker-build in a local env which has the Apple Silicon M1 SO
@@ -45,4 +48,4 @@ WORKDIR /
4548COPY --from=gobuilder /workspace/manager .
4649USER 65532:65532
4750
48- ENTRYPOINT ["/manager"]
51+ ENTRYPOINT ["/manager"]
Original file line number Diff line number Diff line change @@ -17,6 +17,9 @@ COPY ../go.sum go.sum
1717# and so that source changes don't invalidate our downloaded layer
1818RUN go mod download
1919
20+ ENV GOCACHE=/root/.cache/go-build
21+ ENV GOMODCACHE=/go/pkg/mod
22+
2023# Copy the go source
2124COPY ../cmd/manager/main.go cmd/manager/main.go
2225COPY ../api/ api/
You can’t perform that action at this time.
0 commit comments