mirror of
https://ops.gitlab.net/gitlab-org/gitlab-build-images.git
synced 2025-12-09 10:02:56 +01:00
Install git and go packages in final target
Installs git and go packages in final target, as the go packages on alpine are different than on the non-alpine variant.
This commit is contained in:
parent
1496163214
commit
e7e7a7cbe0
1 changed files with 6 additions and 4 deletions
|
|
@ -3,10 +3,7 @@ FROM golang:1.14 AS dependencies
|
|||
ARG KUBEBUILDER_VERSION=2.3.1
|
||||
ARG YQ_VERSION=2.4.1
|
||||
|
||||
RUN go get -u \
|
||||
github.com/onsi/ginkgo/ginkgo \
|
||||
golang.org/x/lint/golint \
|
||||
&& curl -L https://go.kubebuilder.io/dl/${KUBEBUILDER_VERSION}/linux/amd64 | tar -xz -C /tmp/ \
|
||||
RUN curl -L https://go.kubebuilder.io/dl/${KUBEBUILDER_VERSION}/linux/amd64 | tar -xz -C /tmp/ \
|
||||
&& mv /tmp/kubebuilder_${KUBEBUILDER_VERSION}_linux_amd64 /usr/local/kubebuilder \
|
||||
&& ln -sfv /usr/local/kubebuilder/bin/* /usr/local/bin
|
||||
|
||||
|
|
@ -24,3 +21,8 @@ COPY --from=dependencies /go /go
|
|||
COPY --from=dependencies /usr/local/kubebuilder /usr/local/kubebuilder
|
||||
COPY --from=dependencies /usr/local/bin/ /usr/local/bin/
|
||||
COPY --from=dependencies /usr/local/bin/yq /usr/local/bin/yq
|
||||
|
||||
RUN apk add --no-cache git \
|
||||
&& go get -u \
|
||||
github.com/onsi/ginkgo/ginkgo \
|
||||
golang.org/x/lint/golint \
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue