Skip to content

Commit e01a297

Browse files
fix: enable hadolint linter in super linter
Signed-off-by: riya-singhal31 <rsinghal@redhat.com>
1 parent ddd023a commit e01a297

File tree

4 files changed

+7
-5
lines changed

4 files changed

+7
-5
lines changed

.github/workflows/lint-extras.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ jobs:
2323
env:
2424
FILTER_REGEX_EXCLUDE: >
2525
(.*vendor/.*)|(.*tools/vendor/.*)
26-
VALIDATE_DOCKERFILE_HADOLINT: false
2726
VALIDATE_GO: false
2827
VALIDATE_JSCPD: false
2928
VALIDATE_KUBERNETES_KUBECONFORM: false

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
FROM golang:1.20 as builder
33

44
# Copy the contents of the repository
5-
ADD . /workspace/go/src/github.com/csi-addons/kubernetes-csi-addons
5+
COPY . /workspace/go/src/github.com/csi-addons/kubernetes-csi-addons
66

77
ENV GOPATH=/workspace/go CGO_ENABLED=0
88
WORKDIR /workspace/go/src/github.com/csi-addons/kubernetes-csi-addons

build/Containerfile.sidecar

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
FROM golang:1.20 as builder
33

44
# Copy the contents of the repository
5-
ADD . /workspace/go/src/github.com/csi-addons/kubernetes-csi-addons
5+
COPY . /workspace/go/src/github.com/csi-addons/kubernetes-csi-addons
66

77
ENV GOPATH=/workspace/go CGO_ENABLED=0
88
WORKDIR /workspace/go/src/github.com/csi-addons/kubernetes-csi-addons
@@ -12,6 +12,7 @@ RUN make build
1212

1313
# Use distroless as minimal base image to package the sidecar binary
1414
# Refer to https://github.com/GoogleContainerTools/distroless for more details
15+
# hadolint ignore=DL3007
1516
FROM gcr.io/distroless/static:latest
1617
WORKDIR /
1718
COPY --from=builder /workspace/go/src/github.com/csi-addons/kubernetes-csi-addons/bin/csi-addons-sidecar /usr/sbin/

build/Containerfile.tools

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
1+
# hadolint ignore=DL3007
12
FROM quay.io/fedora/fedora:latest
23

3-
ENV GOPATH=/go \
4-
PATH="${GOPATH}/bin:${PATH}"
4+
ENV GOPATH=/go
5+
ENV PATH="${GOPATH}/bin:${PATH}"
56

7+
# hadolint ignore=DL3041
68
RUN dnf -y install \
79
git \
810
make \

0 commit comments

Comments
 (0)