gosec-docker/Dockerfile
Renovate Bot 6a3762b60b
All checks were successful
continuous-integration/drone/pr Build is passing
continuous-integration/drone/push Build is passing
Update docker.io/library/golang Docker tag to v1.17.6
2022-01-30 21:00:59 +00:00

14 lines
482 B
Docker

FROM docker.io/library/golang:1.17.6-alpine AS build
ARG GOSEC_VERSION
RUN apk update && \
apk upgrade && \
apk add git make
RUN if [ ! -z "${GOSEC_VERSION}" ]; then set -ex; go install github.com/securego/gosec/v2/cmd/gosec@${GOSEC_VERSION}; fi
RUN if [ -z "${GOSEC_VERSION}" ]; then set -ex; go install github.com/securego/gosec/v2/cmd/gosec@latest; fi
FROM docker.io/library/alpine:3.15.0
COPY --from=build /go/bin/gosec /usr/bin/gosec
ENTRYPOINT [ "/usr/bin/gosec" ]