From 6fcf01a4b0ab836759f22ade6432f4eb65c62937 Mon Sep 17 00:00:00 2001 From: "Krista LaFentres (she/her)" Date: Thu, 17 Mar 2022 14:15:45 -0500 Subject: [PATCH] Update Dockerfile to go1.18 syntax As of 1.18, `go get ` no longer builds executables. `go install` should be used to install an executable instead. See the deprecation message for more information: https://go.dev/doc/go-get-install-deprecation Pinning to a specific go Docker image will help keep things from breaking unexpectedly in the future --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index db3126e..b341f46 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,14 +2,14 @@ # MailHog Dockerfile # -FROM golang:alpine as builder +FROM golang:1.18-alpine as builder # Install MailHog: RUN apk --no-cache add --virtual build-dependencies \ git \ && mkdir -p /root/gocode \ && export GOPATH=/root/gocode \ - && go get github.com/mailhog/MailHog + && go install github.com/mailhog/MailHog@latest FROM alpine:3 # Add mailhog user/group with uid/gid 1000.