From edd54c6f132aa7c7f2379e34b6adfe043f96f799 Mon Sep 17 00:00:00 2001 From: Nick Keller Date: Wed, 17 Jun 2026 12:34:52 -0400 Subject: [PATCH 1/2] Use mcr golang for draft template --- template/dockerfiles/go/Dockerfile | 4 ++-- template/dockerfiles/gomodule/Dockerfile | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/template/dockerfiles/go/Dockerfile b/template/dockerfiles/go/Dockerfile index 564b27ed3..7bde5b5ef 100644 --- a/template/dockerfiles/go/Dockerfile +++ b/template/dockerfiles/go/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:{{ .Config.GetVariableValue "VERSION" }} +FROM mcr.microsoft.com/oss/go/microsoft/golang:{{ .Config.GetVariableValue "VERSION"}} ENV PORT={{ .Config.GetVariableValue "PORT" }} EXPOSE {{ .Config.GetVariableValue "PORT" }} @@ -9,4 +9,4 @@ ARG GO111MODULE=off RUN go build -v -o app ./main.go RUN mv ./app /go/bin/ -CMD ["app"] \ No newline at end of file +CMD ["app"] diff --git a/template/dockerfiles/gomodule/Dockerfile b/template/dockerfiles/gomodule/Dockerfile index 2e11be4df..76369f990 100644 --- a/template/dockerfiles/gomodule/Dockerfile +++ b/template/dockerfiles/gomodule/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:{{ .Config.GetVariableValue "VERSION" }} AS builder +FROM mcr.microsoft.com/oss/go/microsoft/golang:{{ .Config.GetVariableValue "VERSION"}} WORKDIR /build COPY go.mod go.sum ./ From 5eb8a5921dea7228dabd9a0dfc04f23a3e1b7594 Mon Sep 17 00:00:00 2001 From: Nick Keller Date: Wed, 17 Jun 2026 12:43:02 -0400 Subject: [PATCH 2/2] Fix the fixtures --- pkg/fixtures/dockerfiles/go/Dockerfile | 4 ++-- pkg/fixtures/dockerfiles/gomodule/Dockerfile | 2 +- template/dockerfiles/gomodule/Dockerfile | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pkg/fixtures/dockerfiles/go/Dockerfile b/pkg/fixtures/dockerfiles/go/Dockerfile index 83b7699e6..11de89da9 100644 --- a/pkg/fixtures/dockerfiles/go/Dockerfile +++ b/pkg/fixtures/dockerfiles/go/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.23 +FROM mcr.microsoft.com/oss/go/microsoft/golang:1.23 ENV PORT=80 EXPOSE 80 @@ -9,4 +9,4 @@ ARG GO111MODULE=off RUN go build -v -o app ./main.go RUN mv ./app /go/bin/ -CMD ["app"] \ No newline at end of file +CMD ["app"] diff --git a/pkg/fixtures/dockerfiles/gomodule/Dockerfile b/pkg/fixtures/dockerfiles/gomodule/Dockerfile index 1b334c2b8..37eb1df7c 100644 --- a/pkg/fixtures/dockerfiles/gomodule/Dockerfile +++ b/pkg/fixtures/dockerfiles/gomodule/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.23 AS builder +FROM mcr.microsoft.com/oss/go/microsoft/golang:1.23 as builder WORKDIR /build COPY go.mod go.sum ./ diff --git a/template/dockerfiles/gomodule/Dockerfile b/template/dockerfiles/gomodule/Dockerfile index 76369f990..5404a5795 100644 --- a/template/dockerfiles/gomodule/Dockerfile +++ b/template/dockerfiles/gomodule/Dockerfile @@ -1,4 +1,4 @@ -FROM mcr.microsoft.com/oss/go/microsoft/golang:{{ .Config.GetVariableValue "VERSION"}} +FROM mcr.microsoft.com/oss/go/microsoft/golang:{{ .Config.GetVariableValue "VERSION"}} as builder WORKDIR /build COPY go.mod go.sum ./