From ff548a71b25c3b995319cc27aaafbac6d5a71c03 Mon Sep 17 00:00:00 2001 From: Jeff Hodges Date: Fri, 25 Oct 2024 19:59:19 -0700 Subject: [PATCH] migrate to golang:bookworm image This allows us to keep up to date with recent Go releases and security patches while reducing our configuration in the Dockerfile. We hold on bump the Go version to the latest in a separate change. --- Dockerfile | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/Dockerfile b/Dockerfile index 960bedf32..411085e86 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,15 +1,11 @@ -ARG GO_VERSION=1.22 ARG LIBKMSP11_VERSION=1.6 #------------------------------------------------------------------------------ # Base Debian Image #------------------------------------------------------------------------------ -FROM debian:bookworm AS base -ARG GO_VERSION +FROM golang:1.22.1-bookworm AS base -ENV DEBIAN_FRONTEND='noninteractive' \ - PATH="${PATH}:/usr/lib/go-${GO_VERSION}/bin:/go/bin" \ - GOPATH='/go' +ENV DEBIAN_FRONTEND='noninteractive' ## Enable bookworm-backports RUN echo "deb http://deb.debian.org/debian/ bookworm-backports main" > /etc/apt/sources.list.d/bookworm-backports.list @@ -23,7 +19,6 @@ RUN apt-get update && \ libncurses5 \ devscripts \ apksigner \ - golang-${GO_VERSION} \ gcc \ g++ \ libc6-dev \