From 12255bc10d34a26747cbc891d2ccc4894e416893 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Mart=C3=AD?= Date: Mon, 17 May 2021 10:35:04 +0100 Subject: [PATCH] cmd/shfmt: bump Go and Alpine versions in Dockerfile --- .github/workflows/test.yml | 2 +- cmd/shfmt/Dockerfile | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 9ede3d19e..1ef413df6 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -34,7 +34,7 @@ jobs: - name: Checkout code uses: actions/checkout@v2 - name: Test as root, without cgo, and with busybox - run: docker run -v="$PWD:/pwd" -w=/pwd -e=CGO_ENABLED=0 golang:1.16-alpine go test ./... + run: docker run -v="$PWD:/pwd" -w=/pwd -e=CGO_ENABLED=0 golang:1.16.4-alpine go test ./... docker: name: Build and test Docker images diff --git a/cmd/shfmt/Dockerfile b/cmd/shfmt/Dockerfile index 49f09690a..2247017b9 100644 --- a/cmd/shfmt/Dockerfile +++ b/cmd/shfmt/Dockerfile @@ -1,11 +1,11 @@ -FROM golang:1.16-alpine AS build +FROM golang:1.16.4-alpine AS build WORKDIR /src RUN apk add --no-cache git COPY . . RUN CGO_ENABLED=0 go build -ldflags "-w -s -extldflags '-static' -X main.version=$(git describe --always --dirty --tags)" ./cmd/shfmt -FROM alpine:3.13.2 AS alpine +FROM alpine:3.13.5 AS alpine COPY --from=build /src/shfmt /bin/shfmt COPY "./cmd/shfmt/docker-entrypoint.sh" "/init" ENTRYPOINT ["/init"]