File tree Expand file tree Collapse file tree 1 file changed +11
-7
lines changed Expand file tree Collapse file tree 1 file changed +11
-7
lines changed Original file line number Diff line number Diff line change 1
1
# Stage - builder
2
2
FROM golang as builder
3
3
4
- ARG VER
5
4
6
5
ENV GOOS=linux
7
6
ENV GOARCH=amd64
8
7
ENV CGO_ENABLED=0
9
- ENV VERSION=0.0.0
10
8
11
9
WORKDIR /build
12
10
@@ -15,6 +13,9 @@ COPY go.sum ./
15
13
COPY main.go ./
16
14
RUN go mod download
17
15
16
+ ARG VER=0.0.0
17
+ ENV VERSION=${VER}
18
+
18
19
ADD . src
19
20
20
21
WORKDIR /build/src
@@ -24,15 +25,18 @@ RUN make build
24
25
# Stage - runner
25
26
FROM alpine/helm
26
27
27
- RUN curl -o /bin/kubectl -vf -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" && chmod +x /bin/kubectl && kubectl --help
28
+ # Python
29
+ RUN apk add --update --no-cache python3 && python3 -m ensurepip && pip3 install --upgrade pip setuptools
28
30
29
- # Checkov scanner
30
- RUN apk add --update --no-cache python3
31
- RUN python3 -m ensurepip
32
- RUN pip3 install checkov
31
+ # kubectl
32
+ RUN curl -o /bin/kubectl -vf -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" && chmod +x /bin/kubectl && kubectl --help
33
33
34
34
# Trivy
35
35
RUN curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sh -s -- -b /usr/local/bin v0.18.3
36
+ RUN trivy --version
37
+
38
+ # Checkov scanner
39
+ RUN pip3 install checkov packaging==21.3 && checkov --version
36
40
37
41
COPY --from=builder /build/src/bin/dashboard /bin/helm-dashboard
38
42
You can’t perform that action at this time.
0 commit comments