diff --git a/dockers/agent/core/ngt/Dockerfile b/dockers/agent/core/ngt/Dockerfile index 5240842c26..f3a5c95429 100644 --- a/dockers/agent/core/ngt/Dockerfile +++ b/dockers/agent/core/ngt/Dockerfile @@ -36,6 +36,7 @@ ENV PKG agent/core/ngt ENV PKG_INTERNAL agent/internal ENV APP_NAME ngt +# skipcq: DOK-DL3008 RUN apt-get update && apt-get install -y --no-install-recommends \ ca-certificates \ build-essential \ diff --git a/dockers/agent/sidecar/Dockerfile b/dockers/agent/sidecar/Dockerfile index 955351936b..2933b091bf 100644 --- a/dockers/agent/sidecar/Dockerfile +++ b/dockers/agent/sidecar/Dockerfile @@ -29,13 +29,14 @@ ENV PKG agent/sidecar ENV PKG_INTERNAL agent/internal ENV APP_NAME sidecar +# skipcq: DOK-DL3008 RUN apt-get update && apt-get install -y --no-install-recommends \ upx \ git \ && apt-get clean \ && rm -rf /var/lib/apt/lists/* -RUN mkdir -p $GOPATH/src +RUN mkdir -p "$GOPATH/src" WORKDIR ${GOPATH}/src/github.com/${ORG}/${REPO} diff --git a/dockers/ci/base/Dockerfile b/dockers/ci/base/Dockerfile index c391b3a76a..940c77bfad 100644 --- a/dockers/ci/base/Dockerfile +++ b/dockers/ci/base/Dockerfile @@ -34,6 +34,7 @@ ENV PATH ${PATH}:${GOROOT}/bin:${GOPATH}/bin COPY --from=golang /usr/local/go $GOROOT RUN mkdir -p $GOPATH/src +# skipcq: DOK-DL3008 RUN apt-get update && apt-get install -y --no-install-recommends \ build-essential \ ca-certificates \ diff --git a/dockers/dev/Dockerfile b/dockers/dev/Dockerfile index 3b45a49ae8..2a264f2c7f 100644 --- a/dockers/dev/Dockerfile +++ b/dockers/dev/Dockerfile @@ -18,6 +18,7 @@ ARG MAINTAINER="vdaas.org vald team " FROM ubuntu:devel AS builder +# skipcq: DOK-DL3008 RUN apt-get update && apt-get install -y --no-install-recommends \ ca-certificates \ curl \ @@ -27,9 +28,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ WORKDIR /tmp +# skipcq: DOK-DL3026 FROM mcr.microsoft.com/vscode/devcontainers/go:1 AS base LABEL maintainer "${MAINTAINER}" +# skipcq: DOK-DL3008 RUN apt-get update && apt-get install -y --no-install-recommends \ build-essential \ cmake \ diff --git a/dockers/discoverer/k8s/Dockerfile b/dockers/discoverer/k8s/Dockerfile index 446ebc897b..b62ec90b5b 100644 --- a/dockers/discoverer/k8s/Dockerfile +++ b/dockers/discoverer/k8s/Dockerfile @@ -28,13 +28,14 @@ ENV REPO vald ENV PKG discoverer/k8s ENV APP_NAME discoverer +# skipcq: DOK-DL3008 RUN apt-get update && apt-get install -y --no-install-recommends \ upx \ git \ && apt-get clean \ && rm -rf /var/lib/apt/lists/* -RUN mkdir -p $GOPATH/src +RUN mkdir -p "$GOPATH/src" WORKDIR ${GOPATH}/src/github.com/${ORG}/${REPO} diff --git a/dockers/gateway/filter/Dockerfile b/dockers/gateway/filter/Dockerfile index 0f9b719a3a..cb45fcb1b7 100644 --- a/dockers/gateway/filter/Dockerfile +++ b/dockers/gateway/filter/Dockerfile @@ -28,13 +28,14 @@ ENV REPO vald ENV PKG gateway/filter ENV APP_NAME filter +# skipcq: DOK-DL3008 RUN apt-get update && apt-get install -y --no-install-recommends \ upx \ git \ && apt-get clean \ && rm -rf /var/lib/apt/lists/* -RUN mkdir -p $GOPATH/src +RUN mkdir -p "$GOPATH/src" WORKDIR ${GOPATH}/src/github.com/${ORG}/${REPO} diff --git a/dockers/gateway/lb/Dockerfile b/dockers/gateway/lb/Dockerfile index f31c21c99a..e07602940b 100644 --- a/dockers/gateway/lb/Dockerfile +++ b/dockers/gateway/lb/Dockerfile @@ -28,13 +28,14 @@ ENV REPO vald ENV PKG gateway/lb ENV APP_NAME lb +# skipcq: DOK-DL3008 RUN apt-get update && apt-get install -y --no-install-recommends \ upx \ git \ && apt-get clean \ && rm -rf /var/lib/apt/lists/* -RUN mkdir -p $GOPATH/src +RUN mkdir -p "$GOPATH/src" WORKDIR ${GOPATH}/src/github.com/${ORG}/${REPO} diff --git a/dockers/manager/index/Dockerfile b/dockers/manager/index/Dockerfile index 307aef1af9..20a044b139 100644 --- a/dockers/manager/index/Dockerfile +++ b/dockers/manager/index/Dockerfile @@ -28,13 +28,14 @@ ENV REPO vald ENV PKG manager/index ENV APP_NAME index +# skipcq: DOK-DL3008 RUN apt-get update && apt-get install -y --no-install-recommends \ upx \ git \ && apt-get clean \ && rm -rf /var/lib/apt/lists/* -RUN mkdir -p $GOPATH/src +RUN mkdir -p "$GOPATH/src" WORKDIR ${GOPATH}/src/github.com/${ORG}/${REPO} diff --git a/dockers/operator/helm/Dockerfile b/dockers/operator/helm/Dockerfile index f5ab9cdc97..ff0c24a2a8 100644 --- a/dockers/operator/helm/Dockerfile +++ b/dockers/operator/helm/Dockerfile @@ -24,6 +24,7 @@ ARG VALD_KIND="ValdRelease" ARG VALD_HELM_OPERATOR_KIND="ValdHelmOperatorRelease" ARG MAINTAINER="vdaas.org vald team " +# skipcq: DOK-DL3026 FROM quay.io/operator-framework/helm-operator:${OPERATOR_SDK_VERSION} AS operator FROM golang:${GO_VERSION} AS builder @@ -81,7 +82,8 @@ RUN make helm/schema/vald RUN make helm/schema/vald-helm-operator RUN cp -r charts /charts -RUN apt clean \ +# skipcq: DOK-DL3008 +RUN apt-get clean \ && rm -rf \ /var/lib/apt/lists/* \ /var/cache/* \ diff --git a/dockers/tools/cli/loadtest/Dockerfile b/dockers/tools/cli/loadtest/Dockerfile index 9bbb3445f4..cb217ab18c 100644 --- a/dockers/tools/cli/loadtest/Dockerfile +++ b/dockers/tools/cli/loadtest/Dockerfile @@ -26,6 +26,7 @@ ENV REPO vald ENV APP_NAME loadtest ENV PKG tools/cli/${APP_NAME} +# skipcq: DOK-DL3008 RUN apt-get update && apt-get install -y --no-install-recommends \ upx \ git \ @@ -34,7 +35,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ && apt-get clean \ && rm -rf /var/lib/apt/lists/* -RUN mkdir -p $GOPATH/src +RUN mkdir -p "$GOPATH/src" WORKDIR ${GOPATH}/src/github.com/${ORG}/${REPO} @@ -62,8 +63,9 @@ WORKDIR ${GOPATH}/src/github.com/${ORG}/${REPO} COPY versions/GO_VERSION . COPY versions/VALD_VERSION . COPY .git . -RUN GO_VERSION="$(cat GO_VERSION)" \ - && VALD_VERSION="$(cat VALD_VERSION)" \ +SHELL ["/bin/bash", "-o", "pipefail", "-c"] +RUN GO_VERSION="$(< GO_VERSION)" \ + && VALD_VERSION="$(< VALD_VERSION)" \ && GIT_COMMIT="$(git rev-list -1 HEAD)" \ && CPU_INFO_FLAGS="$(cat /proc/cpuinfo | grep flags | cut -d " " -f 2- | head -1)" \ && GOOS="$(go env GOOS)" \