Pin the base image for v1.7 (#4180)

To improve the reproducibility of the images of velero, this commit pins
the golang and distroless images to specific tag and digest.

Signed-off-by: Daniel Jiang <jiangd@vmware.com>
pull/4182/head
Daniel Jiang 2021-09-22 19:50:07 +08:00 committed by GitHub
parent 8827b4f1d9
commit 3327d209f7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -11,7 +11,7 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
FROM --platform=$BUILDPLATFORM golang:1.16 as builder-env
FROM --platform=$BUILDPLATFORM golang:1.16.8 as builder-env
ARG GOPROXY
ARG PKG
@ -50,7 +50,7 @@ RUN mkdir -p /output/usr/bin && \
go build -o /output/${BIN} \
-ldflags "${LDFLAGS}" ${PKG}/cmd/${BIN}
FROM gcr.io/distroless/base-debian10:nonroot
FROM gcr.io/distroless/base-debian10@sha256:a74f307185001c69bc362a40dbab7b67d410a872678132b187774fa21718fa13
LABEL maintainer="Nolan Brubaker <brubakern@vmware.com>"