From 979680b2b8fcb0acdf7b9c776bf6e857259c3309 Mon Sep 17 00:00:00 2001 From: Matthew Lemon Date: Mon, 22 Apr 2024 14:30:08 +0100 Subject: Changed to 1.20 and using RHEL9 Go image - Using RHEL image registry and Go toolset image (https://catalog.redhat.com/software/containers/rhel9/go-toolset/61df08166d9a1b7b2aab2344?image=6613b725036e65b1bc748a3f&architecture=amd64&container-tabs=packages) - Changed Go version to 1.20 to accommodate image - Removed structured logger --- Dockerfile | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'Dockerfile') diff --git a/Dockerfile b/Dockerfile index 3c01103..0b159f0 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,12 +1,11 @@ -FROM docker.io/golang:alpine +FROM registry.redhat.io/rhel9/go-toolset:1.20.12-3.1712567214 WORKDIR /app -RUN apk add --update npm RUN npm i sass govuk-frontend --save COPY go.mod ./ RUN go mod download && go mod verify COPY . . -RUN go build -v -o /usr/local/bin/app ./cmd/web -CMD ["app"] +RUN go build -v -o /app/bin/app ./cmd/web +CMD ["./bin/app"] EXPOSE 4000 -- cgit v1.2.3