From 2cd4dab7bd702c7315864c428ba286827d50cda3 Mon Sep 17 00:00:00 2001 From: Tianon Gravi Date: Mon, 16 Aug 2021 14:44:20 -0700 Subject: [PATCH 1/2] Update to 1.17 (GA) --- 1.15/alpine3.13/Dockerfile | 104 --------- 1.15/alpine3.14/Dockerfile | 116 ---------- 1.15/buster/Dockerfile | 123 ----------- 1.15/stretch/Dockerfile | 123 ----------- 1.15/windows/nanoserver-1809/Dockerfile | 30 --- .../windows/windowsservercore-1809/Dockerfile | 80 ------- .../windowsservercore-ltsc2016/Dockerfile | 80 ------- {1.17-rc => 1.17}/alpine3.13/Dockerfile | 6 +- {1.17-rc => 1.17}/alpine3.14/Dockerfile | 6 +- {1.17-rc => 1.17}/buster/Dockerfile | 30 +-- {1.17-rc => 1.17}/stretch/Dockerfile | 30 +-- .../windows/nanoserver-1809/Dockerfile | 4 +- .../windows/windowsservercore-1809/Dockerfile | 6 +- .../windowsservercore-ltsc2016/Dockerfile | 6 +- generate-stackbrew-library.sh | 4 +- versions.json | 209 +++--------------- 16 files changed, 78 insertions(+), 879 deletions(-) delete mode 100644 1.15/alpine3.13/Dockerfile delete mode 100644 1.15/alpine3.14/Dockerfile delete mode 100644 1.15/buster/Dockerfile delete mode 100644 1.15/stretch/Dockerfile delete mode 100644 1.15/windows/nanoserver-1809/Dockerfile delete mode 100644 1.15/windows/windowsservercore-1809/Dockerfile delete mode 100644 1.15/windows/windowsservercore-ltsc2016/Dockerfile rename {1.17-rc => 1.17}/alpine3.13/Dockerfile (95%) rename {1.17-rc => 1.17}/alpine3.14/Dockerfile (94%) rename {1.17-rc => 1.17}/buster/Dockerfile (74%) rename {1.17-rc => 1.17}/stretch/Dockerfile (74%) rename {1.17-rc => 1.17}/windows/nanoserver-1809/Dockerfile (88%) rename {1.17-rc => 1.17}/windows/windowsservercore-1809/Dockerfile (95%) rename {1.17-rc => 1.17}/windows/windowsservercore-ltsc2016/Dockerfile (95%) diff --git a/1.15/alpine3.13/Dockerfile b/1.15/alpine3.13/Dockerfile deleted file mode 100644 index 11954723..00000000 --- a/1.15/alpine3.13/Dockerfile +++ /dev/null @@ -1,104 +0,0 @@ -# -# NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" -# -# PLEASE DO NOT EDIT IT DIRECTLY. -# - -FROM alpine:3.13 - -RUN apk add --no-cache \ - ca-certificates - -# set up nsswitch.conf for Go's "netgo" implementation -# - https://github.com/golang/go/blob/go1.9.1/src/net/conf.go#L194-L275 -# - docker run --rm debian:stretch grep '^hosts:' /etc/nsswitch.conf -RUN [ ! -e /etc/nsswitch.conf ] && echo 'hosts: files dns' > /etc/nsswitch.conf - -ENV PATH /usr/local/go/bin:$PATH - -ENV GOLANG_VERSION 1.15.15 - -RUN set -eux; \ - apk add --no-cache --virtual .build-deps \ - bash \ - gcc \ - gnupg \ - go \ - musl-dev \ - openssl \ - ; \ - apkArch="$(apk --print-arch)"; \ - case "$apkArch" in \ - 'x86_64') \ - export GOARCH='amd64' GOOS='linux'; \ - ;; \ - 'armhf') \ - export GOARCH='arm' GOARM='6' GOOS='linux'; \ - ;; \ - 'armv7') \ - export GOARCH='arm' GOARM='7' GOOS='linux'; \ - ;; \ - 'aarch64') \ - export GOARCH='arm64' GOOS='linux'; \ - ;; \ - 'x86') \ - export GO386='387' GOARCH='386' GOOS='linux'; \ - ;; \ - 'ppc64le') \ - export GOARCH='ppc64le' GOOS='linux'; \ - ;; \ - 's390x') \ - export GOARCH='s390x' GOOS='linux'; \ - ;; \ - *) echo >&2 "error: unsupported architecture '$apkArch' (likely packaging update needed)"; exit 1 ;; \ - esac; \ - \ -# https://github.com/golang/go/issues/38536#issuecomment-616897960 - url='https://dl.google.com/go/go1.15.15.src.tar.gz'; \ - sha256='0662ae3813330280d5f1a97a2ee23bbdbe3a5a7cfa6001b24a9873a19a0dc7ec'; \ - \ - wget -O go.tgz.asc "$url.asc"; \ - wget -O go.tgz "$url"; \ - echo "$sha256 *go.tgz" | sha256sum -c -; \ - \ -# https://github.com/golang/go/issues/14739#issuecomment-324767697 - export GNUPGHOME="$(mktemp -d)"; \ -# https://www.google.com/linuxrepositories/ - gpg --batch --keyserver keyserver.ubuntu.com --recv-keys 'EB4C 1BFD 4F04 2F6D DDCC EC91 7721 F63B D38B 4796'; \ - gpg --batch --verify go.tgz.asc go.tgz; \ - gpgconf --kill all; \ - rm -rf "$GNUPGHOME" go.tgz.asc; \ - \ - tar -C /usr/local -xzf go.tgz; \ - rm go.tgz; \ - \ - ( \ - cd /usr/local/go/src; \ -# set GOROOT_BOOTSTRAP + GOHOST* such that we can build Go successfully - export GOROOT_BOOTSTRAP="$(go env GOROOT)" GOHOSTOS="$GOOS" GOHOSTARCH="$GOARCH"; \ - ./make.bash; \ - ); \ - \ -# pre-compile the standard library, just like the official binary release tarballs do - go install std; \ -# go install: -race is only supported on linux/amd64, linux/ppc64le, linux/arm64, freebsd/amd64, netbsd/amd64, darwin/amd64 and windows/amd64 -# go install -race std; \ - \ - apk del --no-network .build-deps; \ - \ -# remove a few intermediate / bootstrapping files the official binary release tarballs do not contain - rm -rf \ - /usr/local/go/pkg/*/cmd \ - /usr/local/go/pkg/bootstrap \ - /usr/local/go/pkg/obj \ - /usr/local/go/pkg/tool/*/api \ - /usr/local/go/pkg/tool/*/go_bootstrap \ - /usr/local/go/src/cmd/dist/dist \ - ; \ - \ - go version - -ENV GOPATH /go -ENV PATH $GOPATH/bin:$PATH -RUN mkdir -p "$GOPATH/src" "$GOPATH/bin" && chmod -R 777 "$GOPATH" -WORKDIR $GOPATH diff --git a/1.15/alpine3.14/Dockerfile b/1.15/alpine3.14/Dockerfile deleted file mode 100644 index 6aeffbb9..00000000 --- a/1.15/alpine3.14/Dockerfile +++ /dev/null @@ -1,116 +0,0 @@ -# -# NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" -# -# PLEASE DO NOT EDIT IT DIRECTLY. -# - -FROM alpine:3.14 - -RUN apk add --no-cache \ - ca-certificates - -# set up nsswitch.conf for Go's "netgo" implementation -# - https://github.com/golang/go/blob/go1.9.1/src/net/conf.go#L194-L275 -# - docker run --rm debian:stretch grep '^hosts:' /etc/nsswitch.conf -RUN [ ! -e /etc/nsswitch.conf ] && echo 'hosts: files dns' > /etc/nsswitch.conf - -ENV PATH /usr/local/go/bin:$PATH - -ENV GOLANG_VERSION 1.15.15 - -RUN set -eux; \ - apk add --no-cache --virtual .build-deps \ - bash \ - gcc \ - gnupg \ - go \ - musl-dev \ - openssl \ - ; \ - apkArch="$(apk --print-arch)"; \ - case "$apkArch" in \ - 'x86_64') \ - export GOARCH='amd64' GOOS='linux'; \ - ;; \ - 'armhf') \ - export GOARCH='arm' GOARM='6' GOOS='linux'; \ - ;; \ - 'armv7') \ - export GOARCH='arm' GOARM='7' GOOS='linux'; \ - ;; \ - 'aarch64') \ - export GOARCH='arm64' GOOS='linux'; \ - ;; \ - 'x86') \ - export GO386='387' GOARCH='386' GOOS='linux'; \ - ;; \ - 'ppc64le') \ - export GOARCH='ppc64le' GOOS='linux'; \ - ;; \ - 's390x') \ - export GOARCH='s390x' GOOS='linux'; \ - ;; \ - *) echo >&2 "error: unsupported architecture '$apkArch' (likely packaging update needed)"; exit 1 ;; \ - esac; \ - \ -# https://github.com/golang/go/issues/38536#issuecomment-616897960 - url='https://dl.google.com/go/go1.15.15.src.tar.gz'; \ - sha256='0662ae3813330280d5f1a97a2ee23bbdbe3a5a7cfa6001b24a9873a19a0dc7ec'; \ - \ - wget -O go.tgz.asc "$url.asc"; \ - wget -O go.tgz "$url"; \ - echo "$sha256 *go.tgz" | sha256sum -c -; \ - \ -# https://github.com/golang/go/issues/14739#issuecomment-324767697 - export GNUPGHOME="$(mktemp -d)"; \ -# https://www.google.com/linuxrepositories/ - gpg --batch --keyserver keyserver.ubuntu.com --recv-keys 'EB4C 1BFD 4F04 2F6D DDCC EC91 7721 F63B D38B 4796'; \ - gpg --batch --verify go.tgz.asc go.tgz; \ - gpgconf --kill all; \ - rm -rf "$GNUPGHOME" go.tgz.asc; \ - \ - tar -C /usr/local -xzf go.tgz; \ - rm go.tgz; \ - \ - ( \ - cd /usr/local/go/src; \ -# set GOROOT_BOOTSTRAP + GOHOST* such that we can build Go successfully - export GOROOT_BOOTSTRAP="$(go env GOROOT)" GOHOSTOS="$GOOS" GOHOSTARCH="$GOARCH"; \ - if [ -n "${GO386:-}" ]; then \ -# https://github.com/docker-library/golang/issues/359 -> https://github.com/golang/go/issues/44500 -# Go 1.15 + Alpine 3.14 == Go 1.16 bootstrap -# Go 1.16 + Alpine 3.13 == Go 1.15 bootstrap -# (once Go 1.15 *and* Alpine 3.13 go away, we can remove this) - GO386= ./bootstrap.bash; \ - export GOROOT_BOOTSTRAP="/usr/local/go-$GOOS-$GOARCH-bootstrap"; \ - "$GOROOT_BOOTSTRAP/bin/go" version; \ - fi; \ - ./make.bash; \ - if [ -n "${GO386:-}" ]; then \ - rm -rf "$GOROOT_BOOTSTRAP"; \ - fi; \ - ); \ - \ -# pre-compile the standard library, just like the official binary release tarballs do - go install std; \ -# go install: -race is only supported on linux/amd64, linux/ppc64le, linux/arm64, freebsd/amd64, netbsd/amd64, darwin/amd64 and windows/amd64 -# go install -race std; \ - \ - apk del --no-network .build-deps; \ - \ -# remove a few intermediate / bootstrapping files the official binary release tarballs do not contain - rm -rf \ - /usr/local/go/pkg/*/cmd \ - /usr/local/go/pkg/bootstrap \ - /usr/local/go/pkg/obj \ - /usr/local/go/pkg/tool/*/api \ - /usr/local/go/pkg/tool/*/go_bootstrap \ - /usr/local/go/src/cmd/dist/dist \ - ; \ - \ - go version - -ENV GOPATH /go -ENV PATH $GOPATH/bin:$PATH -RUN mkdir -p "$GOPATH/src" "$GOPATH/bin" && chmod -R 777 "$GOPATH" -WORKDIR $GOPATH diff --git a/1.15/buster/Dockerfile b/1.15/buster/Dockerfile deleted file mode 100644 index 1622c886..00000000 --- a/1.15/buster/Dockerfile +++ /dev/null @@ -1,123 +0,0 @@ -# -# NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" -# -# PLEASE DO NOT EDIT IT DIRECTLY. -# - -FROM buildpack-deps:buster-scm - -# gcc for cgo -RUN apt-get update && apt-get install -y --no-install-recommends \ - g++ \ - gcc \ - libc6-dev \ - make \ - pkg-config \ - && rm -rf /var/lib/apt/lists/* - -ENV PATH /usr/local/go/bin:$PATH - -ENV GOLANG_VERSION 1.15.15 - -RUN set -eux; \ - \ - dpkgArch="$(dpkg --print-architecture)"; \ - url=; \ - case "${dpkgArch##*-}" in \ - 'amd64') \ - url='https://dl.google.com/go/go1.15.15.linux-amd64.tar.gz'; \ - sha256='0885cf046a9f099e260d98d9ec5d19ea9328f34c8dc4956e1d3cd87daaddb345'; \ - ;; \ - 'armel') \ - export GOARCH='arm' GOARM='5' GOOS='linux'; \ - ;; \ - 'armhf') \ - url='https://dl.google.com/go/go1.15.15.linux-armv6l.tar.gz'; \ - sha256='7192603af50afb23c9d8cd14d2b2c19e0985a34d3eca685fa098df7893000d19'; \ - ;; \ - 'arm64') \ - url='https://dl.google.com/go/go1.15.15.linux-arm64.tar.gz'; \ - sha256='714abb01af210473dd6af331094ad6847162eff81a7fc7241d24f5a85496c9fa'; \ - ;; \ - 'i386') \ - url='https://dl.google.com/go/go1.15.15.linux-386.tar.gz'; \ - sha256='3310fb0e48b0907bb520f6e3c6dcff63cc0913b92a76456f12980d0eb13b77d4'; \ - ;; \ - 'mips64el') \ - export GOARCH='mips64le' GOOS='linux'; \ - ;; \ - 'ppc64el') \ - url='https://dl.google.com/go/go1.15.15.linux-ppc64le.tar.gz'; \ - sha256='37f3b99e21d0324a6583159e14e42e57e56561abbf7bf68bef3d8f57b29e39c0'; \ - ;; \ - 's390x') \ - url='https://dl.google.com/go/go1.15.15.linux-s390x.tar.gz'; \ - sha256='eae39d97df6b758636d5427be0b083dbf9d49007b302825ac6c8645de039aaab'; \ - ;; \ - *) echo >&2 "error: unsupported architecture '$dpkgArch' (likely packaging update needed)"; exit 1 ;; \ - esac; \ - build=; \ - if [ -z "$url" ]; then \ -# https://github.com/golang/go/issues/38536#issuecomment-616897960 - build=1; \ - url='https://dl.google.com/go/go1.15.15.src.tar.gz'; \ - sha256='0662ae3813330280d5f1a97a2ee23bbdbe3a5a7cfa6001b24a9873a19a0dc7ec'; \ - echo >&2; \ - echo >&2 "warning: current architecture ($dpkgArch) does not have a corresponding Go binary release; will be building from source"; \ - echo >&2; \ - fi; \ - \ - wget -O go.tgz.asc "$url.asc" --progress=dot:giga; \ - wget -O go.tgz "$url" --progress=dot:giga; \ - echo "$sha256 *go.tgz" | sha256sum --strict --check -; \ - \ -# https://github.com/golang/go/issues/14739#issuecomment-324767697 - export GNUPGHOME="$(mktemp -d)"; \ -# https://www.google.com/linuxrepositories/ - gpg --batch --keyserver keyserver.ubuntu.com --recv-keys 'EB4C 1BFD 4F04 2F6D DDCC EC91 7721 F63B D38B 4796'; \ - gpg --batch --verify go.tgz.asc go.tgz; \ - gpgconf --kill all; \ - rm -rf "$GNUPGHOME" go.tgz.asc; \ - \ - tar -C /usr/local -xzf go.tgz; \ - rm go.tgz; \ - \ - if [ -n "$build" ]; then \ - savedAptMark="$(apt-mark showmanual)"; \ - apt-get update; \ - apt-get install -y --no-install-recommends golang-go; \ - \ - ( \ - cd /usr/local/go/src; \ -# set GOROOT_BOOTSTRAP + GOHOST* such that we can build Go successfully - export GOROOT_BOOTSTRAP="$(go env GOROOT)" GOHOSTOS="$GOOS" GOHOSTARCH="$GOARCH"; \ - ./make.bash; \ - ); \ - \ - apt-mark auto '.*' > /dev/null; \ - apt-mark manual $savedAptMark > /dev/null; \ - apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ - rm -rf /var/lib/apt/lists/*; \ - \ -# pre-compile the standard library, just like the official binary release tarballs do - go install std; \ -# go install: -race is only supported on linux/amd64, linux/ppc64le, linux/arm64, freebsd/amd64, netbsd/amd64, darwin/amd64 and windows/amd64 -# go install -race std; \ - \ -# remove a few intermediate / bootstrapping files the official binary release tarballs do not contain - rm -rf \ - /usr/local/go/pkg/*/cmd \ - /usr/local/go/pkg/bootstrap \ - /usr/local/go/pkg/obj \ - /usr/local/go/pkg/tool/*/api \ - /usr/local/go/pkg/tool/*/go_bootstrap \ - /usr/local/go/src/cmd/dist/dist \ - ; \ - fi; \ - \ - go version - -ENV GOPATH /go -ENV PATH $GOPATH/bin:$PATH -RUN mkdir -p "$GOPATH/src" "$GOPATH/bin" && chmod -R 777 "$GOPATH" -WORKDIR $GOPATH diff --git a/1.15/stretch/Dockerfile b/1.15/stretch/Dockerfile deleted file mode 100644 index 7f48ec76..00000000 --- a/1.15/stretch/Dockerfile +++ /dev/null @@ -1,123 +0,0 @@ -# -# NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" -# -# PLEASE DO NOT EDIT IT DIRECTLY. -# - -FROM buildpack-deps:stretch-scm - -# gcc for cgo -RUN apt-get update && apt-get install -y --no-install-recommends \ - g++ \ - gcc \ - libc6-dev \ - make \ - pkg-config \ - && rm -rf /var/lib/apt/lists/* - -ENV PATH /usr/local/go/bin:$PATH - -ENV GOLANG_VERSION 1.15.15 - -RUN set -eux; \ - \ - dpkgArch="$(dpkg --print-architecture)"; \ - url=; \ - case "${dpkgArch##*-}" in \ - 'amd64') \ - url='https://dl.google.com/go/go1.15.15.linux-amd64.tar.gz'; \ - sha256='0885cf046a9f099e260d98d9ec5d19ea9328f34c8dc4956e1d3cd87daaddb345'; \ - ;; \ - 'armel') \ - export GOARCH='arm' GOARM='5' GOOS='linux'; \ - ;; \ - 'armhf') \ - url='https://dl.google.com/go/go1.15.15.linux-armv6l.tar.gz'; \ - sha256='7192603af50afb23c9d8cd14d2b2c19e0985a34d3eca685fa098df7893000d19'; \ - ;; \ - 'arm64') \ - url='https://dl.google.com/go/go1.15.15.linux-arm64.tar.gz'; \ - sha256='714abb01af210473dd6af331094ad6847162eff81a7fc7241d24f5a85496c9fa'; \ - ;; \ - 'i386') \ - url='https://dl.google.com/go/go1.15.15.linux-386.tar.gz'; \ - sha256='3310fb0e48b0907bb520f6e3c6dcff63cc0913b92a76456f12980d0eb13b77d4'; \ - ;; \ - 'mips64el') \ - export GOARCH='mips64le' GOOS='linux'; \ - ;; \ - 'ppc64el') \ - url='https://dl.google.com/go/go1.15.15.linux-ppc64le.tar.gz'; \ - sha256='37f3b99e21d0324a6583159e14e42e57e56561abbf7bf68bef3d8f57b29e39c0'; \ - ;; \ - 's390x') \ - url='https://dl.google.com/go/go1.15.15.linux-s390x.tar.gz'; \ - sha256='eae39d97df6b758636d5427be0b083dbf9d49007b302825ac6c8645de039aaab'; \ - ;; \ - *) echo >&2 "error: unsupported architecture '$dpkgArch' (likely packaging update needed)"; exit 1 ;; \ - esac; \ - build=; \ - if [ -z "$url" ]; then \ -# https://github.com/golang/go/issues/38536#issuecomment-616897960 - build=1; \ - url='https://dl.google.com/go/go1.15.15.src.tar.gz'; \ - sha256='0662ae3813330280d5f1a97a2ee23bbdbe3a5a7cfa6001b24a9873a19a0dc7ec'; \ - echo >&2; \ - echo >&2 "warning: current architecture ($dpkgArch) does not have a corresponding Go binary release; will be building from source"; \ - echo >&2; \ - fi; \ - \ - wget -O go.tgz.asc "$url.asc" --progress=dot:giga; \ - wget -O go.tgz "$url" --progress=dot:giga; \ - echo "$sha256 *go.tgz" | sha256sum --strict --check -; \ - \ -# https://github.com/golang/go/issues/14739#issuecomment-324767697 - export GNUPGHOME="$(mktemp -d)"; \ -# https://www.google.com/linuxrepositories/ - gpg --batch --keyserver keyserver.ubuntu.com --recv-keys 'EB4C 1BFD 4F04 2F6D DDCC EC91 7721 F63B D38B 4796'; \ - gpg --batch --verify go.tgz.asc go.tgz; \ - gpgconf --kill all; \ - rm -rf "$GNUPGHOME" go.tgz.asc; \ - \ - tar -C /usr/local -xzf go.tgz; \ - rm go.tgz; \ - \ - if [ -n "$build" ]; then \ - savedAptMark="$(apt-mark showmanual)"; \ - apt-get update; \ - apt-get install -y --no-install-recommends golang-go; \ - \ - ( \ - cd /usr/local/go/src; \ -# set GOROOT_BOOTSTRAP + GOHOST* such that we can build Go successfully - export GOROOT_BOOTSTRAP="$(go env GOROOT)" GOHOSTOS="$GOOS" GOHOSTARCH="$GOARCH"; \ - ./make.bash; \ - ); \ - \ - apt-mark auto '.*' > /dev/null; \ - apt-mark manual $savedAptMark > /dev/null; \ - apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ - rm -rf /var/lib/apt/lists/*; \ - \ -# pre-compile the standard library, just like the official binary release tarballs do - go install std; \ -# go install: -race is only supported on linux/amd64, linux/ppc64le, linux/arm64, freebsd/amd64, netbsd/amd64, darwin/amd64 and windows/amd64 -# go install -race std; \ - \ -# remove a few intermediate / bootstrapping files the official binary release tarballs do not contain - rm -rf \ - /usr/local/go/pkg/*/cmd \ - /usr/local/go/pkg/bootstrap \ - /usr/local/go/pkg/obj \ - /usr/local/go/pkg/tool/*/api \ - /usr/local/go/pkg/tool/*/go_bootstrap \ - /usr/local/go/src/cmd/dist/dist \ - ; \ - fi; \ - \ - go version - -ENV GOPATH /go -ENV PATH $GOPATH/bin:$PATH -RUN mkdir -p "$GOPATH/src" "$GOPATH/bin" && chmod -R 777 "$GOPATH" -WORKDIR $GOPATH diff --git a/1.15/windows/nanoserver-1809/Dockerfile b/1.15/windows/nanoserver-1809/Dockerfile deleted file mode 100644 index 2b41bfdc..00000000 --- a/1.15/windows/nanoserver-1809/Dockerfile +++ /dev/null @@ -1,30 +0,0 @@ -# -# NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" -# -# PLEASE DO NOT EDIT IT DIRECTLY. -# - -FROM mcr.microsoft.com/windows/nanoserver:1809 - -SHELL ["cmd", "/S", "/C"] - -# no Git installed (intentionally) -# -- Nano Server is "Windows Slim" - -# ideally, this would be C:\go to match Linux a bit closer, but C:\go was the default install path for Go itself on Windows -ENV GOPATH C:\\gopath -# (https://golang.org/cl/283600) - -# PATH isn't actually set in the Docker image, so we have to set it from within the container -USER ContainerAdministrator -RUN setx /m PATH "%GOPATH%\bin;C:\go\bin;%PATH%" -USER ContainerUser -# doing this first to share cache across versions more aggressively - -ENV GOLANG_VERSION 1.15.15 - -# Docker's Windows path parsing is absolutely *cursed*; please just trust me on this one -Tianon -COPY --from=golang:1.15.15-windowsservercore-1809 ["C:\\\\go","C:\\\\go"] -RUN go version - -WORKDIR $GOPATH diff --git a/1.15/windows/windowsservercore-1809/Dockerfile b/1.15/windows/windowsservercore-1809/Dockerfile deleted file mode 100644 index 7e7c5a68..00000000 --- a/1.15/windows/windowsservercore-1809/Dockerfile +++ /dev/null @@ -1,80 +0,0 @@ -# -# NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" -# -# PLEASE DO NOT EDIT IT DIRECTLY. -# - -FROM mcr.microsoft.com/windows/servercore:1809 - -# $ProgressPreference: https://github.com/PowerShell/PowerShell/issues/2138#issuecomment-251261324 -SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] - -# install MinGit (especially for "go get") -# https://blogs.msdn.microsoft.com/visualstudioalm/2016/09/03/whats-new-in-git-for-windows-2-10/ -# "Essentially, it is a Git for Windows that was stripped down as much as possible without sacrificing the functionality in which 3rd-party software may be interested." -# "It currently requires only ~45MB on disk." -ENV GIT_VERSION 2.23.0 -ENV GIT_TAG v${GIT_VERSION}.windows.1 -ENV GIT_DOWNLOAD_URL https://github.com/git-for-windows/git/releases/download/${GIT_TAG}/MinGit-${GIT_VERSION}-64-bit.zip -ENV GIT_DOWNLOAD_SHA256 8f65208f92c0b4c3ae4c0cf02d4b5f6791d539cd1a07b2df62b7116467724735 -# steps inspired by "chcolateyInstall.ps1" from "git.install" (https://chocolatey.org/packages/git.install) -RUN Write-Host ('Downloading {0} ...' -f $env:GIT_DOWNLOAD_URL); \ - [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; \ - Invoke-WebRequest -Uri $env:GIT_DOWNLOAD_URL -OutFile 'git.zip'; \ - \ - Write-Host ('Verifying sha256 ({0}) ...' -f $env:GIT_DOWNLOAD_SHA256); \ - if ((Get-FileHash git.zip -Algorithm sha256).Hash -ne $env:GIT_DOWNLOAD_SHA256) { \ - Write-Host 'FAILED!'; \ - exit 1; \ - }; \ - \ - Write-Host 'Expanding ...'; \ - Expand-Archive -Path git.zip -DestinationPath C:\git\.; \ - \ - Write-Host 'Removing ...'; \ - Remove-Item git.zip -Force; \ - \ - Write-Host 'Updating PATH ...'; \ - $env:PATH = 'C:\git\cmd;C:\git\mingw64\bin;C:\git\usr\bin;' + $env:PATH; \ - [Environment]::SetEnvironmentVariable('PATH', $env:PATH, [EnvironmentVariableTarget]::Machine); \ - \ - Write-Host 'Verifying install ("git version") ...'; \ - git version; \ - \ - Write-Host 'Complete.'; - -# ideally, this would be C:\go to match Linux a bit closer, but C:\go was the default install path for Go itself on Windows -ENV GOPATH C:\\gopath -# (https://golang.org/cl/283600) - -# PATH isn't actually set in the Docker image, so we have to set it from within the container -RUN $newPath = ('{0}\bin;C:\go\bin;{1}' -f $env:GOPATH, $env:PATH); \ - Write-Host ('Updating PATH: {0}' -f $newPath); \ - [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine); -# doing this first to share cache across versions more aggressively - -ENV GOLANG_VERSION 1.15.15 - -RUN $url = 'https://dl.google.com/go/go1.15.15.windows-amd64.zip'; \ - Write-Host ('Downloading {0} ...' -f $url); \ - Invoke-WebRequest -Uri $url -OutFile 'go.zip'; \ - \ - $sha256 = '7df7bf948dcc8ec0a3902e3301d17cbb5c2ebb01297d686ee2302e41f4ac6e10'; \ - Write-Host ('Verifying sha256 ({0}) ...' -f $sha256); \ - if ((Get-FileHash go.zip -Algorithm sha256).Hash -ne $sha256) { \ - Write-Host 'FAILED!'; \ - exit 1; \ - }; \ - \ - Write-Host 'Expanding ...'; \ - Expand-Archive go.zip -DestinationPath C:\; \ - \ - Write-Host 'Removing ...'; \ - Remove-Item go.zip -Force; \ - \ - Write-Host 'Verifying install ("go version") ...'; \ - go version; \ - \ - Write-Host 'Complete.'; - -WORKDIR $GOPATH diff --git a/1.15/windows/windowsservercore-ltsc2016/Dockerfile b/1.15/windows/windowsservercore-ltsc2016/Dockerfile deleted file mode 100644 index 41b0be36..00000000 --- a/1.15/windows/windowsservercore-ltsc2016/Dockerfile +++ /dev/null @@ -1,80 +0,0 @@ -# -# NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" -# -# PLEASE DO NOT EDIT IT DIRECTLY. -# - -FROM mcr.microsoft.com/windows/servercore:ltsc2016 - -# $ProgressPreference: https://github.com/PowerShell/PowerShell/issues/2138#issuecomment-251261324 -SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] - -# install MinGit (especially for "go get") -# https://blogs.msdn.microsoft.com/visualstudioalm/2016/09/03/whats-new-in-git-for-windows-2-10/ -# "Essentially, it is a Git for Windows that was stripped down as much as possible without sacrificing the functionality in which 3rd-party software may be interested." -# "It currently requires only ~45MB on disk." -ENV GIT_VERSION 2.23.0 -ENV GIT_TAG v${GIT_VERSION}.windows.1 -ENV GIT_DOWNLOAD_URL https://github.com/git-for-windows/git/releases/download/${GIT_TAG}/MinGit-${GIT_VERSION}-64-bit.zip -ENV GIT_DOWNLOAD_SHA256 8f65208f92c0b4c3ae4c0cf02d4b5f6791d539cd1a07b2df62b7116467724735 -# steps inspired by "chcolateyInstall.ps1" from "git.install" (https://chocolatey.org/packages/git.install) -RUN Write-Host ('Downloading {0} ...' -f $env:GIT_DOWNLOAD_URL); \ - [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; \ - Invoke-WebRequest -Uri $env:GIT_DOWNLOAD_URL -OutFile 'git.zip'; \ - \ - Write-Host ('Verifying sha256 ({0}) ...' -f $env:GIT_DOWNLOAD_SHA256); \ - if ((Get-FileHash git.zip -Algorithm sha256).Hash -ne $env:GIT_DOWNLOAD_SHA256) { \ - Write-Host 'FAILED!'; \ - exit 1; \ - }; \ - \ - Write-Host 'Expanding ...'; \ - Expand-Archive -Path git.zip -DestinationPath C:\git\.; \ - \ - Write-Host 'Removing ...'; \ - Remove-Item git.zip -Force; \ - \ - Write-Host 'Updating PATH ...'; \ - $env:PATH = 'C:\git\cmd;C:\git\mingw64\bin;C:\git\usr\bin;' + $env:PATH; \ - [Environment]::SetEnvironmentVariable('PATH', $env:PATH, [EnvironmentVariableTarget]::Machine); \ - \ - Write-Host 'Verifying install ("git version") ...'; \ - git version; \ - \ - Write-Host 'Complete.'; - -# ideally, this would be C:\go to match Linux a bit closer, but C:\go was the default install path for Go itself on Windows -ENV GOPATH C:\\gopath -# (https://golang.org/cl/283600) - -# PATH isn't actually set in the Docker image, so we have to set it from within the container -RUN $newPath = ('{0}\bin;C:\go\bin;{1}' -f $env:GOPATH, $env:PATH); \ - Write-Host ('Updating PATH: {0}' -f $newPath); \ - [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine); -# doing this first to share cache across versions more aggressively - -ENV GOLANG_VERSION 1.15.15 - -RUN $url = 'https://dl.google.com/go/go1.15.15.windows-amd64.zip'; \ - Write-Host ('Downloading {0} ...' -f $url); \ - Invoke-WebRequest -Uri $url -OutFile 'go.zip'; \ - \ - $sha256 = '7df7bf948dcc8ec0a3902e3301d17cbb5c2ebb01297d686ee2302e41f4ac6e10'; \ - Write-Host ('Verifying sha256 ({0}) ...' -f $sha256); \ - if ((Get-FileHash go.zip -Algorithm sha256).Hash -ne $sha256) { \ - Write-Host 'FAILED!'; \ - exit 1; \ - }; \ - \ - Write-Host 'Expanding ...'; \ - Expand-Archive go.zip -DestinationPath C:\; \ - \ - Write-Host 'Removing ...'; \ - Remove-Item go.zip -Force; \ - \ - Write-Host 'Verifying install ("go version") ...'; \ - go version; \ - \ - Write-Host 'Complete.'; - -WORKDIR $GOPATH diff --git a/1.17-rc/alpine3.13/Dockerfile b/1.17/alpine3.13/Dockerfile similarity index 95% rename from 1.17-rc/alpine3.13/Dockerfile rename to 1.17/alpine3.13/Dockerfile index 8e4d651c..d7134c34 100644 --- a/1.17-rc/alpine3.13/Dockerfile +++ b/1.17/alpine3.13/Dockerfile @@ -16,7 +16,7 @@ RUN [ ! -e /etc/nsswitch.conf ] && echo 'hosts: files dns' > /etc/nsswitch.conf ENV PATH /usr/local/go/bin:$PATH -ENV GOLANG_VERSION 1.17rc2 +ENV GOLANG_VERSION 1.17 RUN set -eux; \ apk add --no-cache --virtual .build-deps \ @@ -54,8 +54,8 @@ RUN set -eux; \ esac; \ \ # https://github.com/golang/go/issues/38536#issuecomment-616897960 - url='https://dl.google.com/go/go1.17rc2.src.tar.gz'; \ - sha256='5ab21d75552390c63087518e4eba2972fb009aea97ff2bcc42dff264c5f46fe9'; \ + url='https://dl.google.com/go/go1.17.src.tar.gz'; \ + sha256='3a70e5055509f347c0fb831ca07a2bf3b531068f349b14a3c652e9b5b67beb5d'; \ \ wget -O go.tgz.asc "$url.asc"; \ wget -O go.tgz "$url"; \ diff --git a/1.17-rc/alpine3.14/Dockerfile b/1.17/alpine3.14/Dockerfile similarity index 94% rename from 1.17-rc/alpine3.14/Dockerfile rename to 1.17/alpine3.14/Dockerfile index 21a01448..92da153a 100644 --- a/1.17-rc/alpine3.14/Dockerfile +++ b/1.17/alpine3.14/Dockerfile @@ -16,7 +16,7 @@ RUN [ ! -e /etc/nsswitch.conf ] && echo 'hosts: files dns' > /etc/nsswitch.conf ENV PATH /usr/local/go/bin:$PATH -ENV GOLANG_VERSION 1.17rc2 +ENV GOLANG_VERSION 1.17 RUN set -eux; \ apk add --no-cache --virtual .build-deps \ @@ -54,8 +54,8 @@ RUN set -eux; \ esac; \ \ # https://github.com/golang/go/issues/38536#issuecomment-616897960 - url='https://dl.google.com/go/go1.17rc2.src.tar.gz'; \ - sha256='5ab21d75552390c63087518e4eba2972fb009aea97ff2bcc42dff264c5f46fe9'; \ + url='https://dl.google.com/go/go1.17.src.tar.gz'; \ + sha256='3a70e5055509f347c0fb831ca07a2bf3b531068f349b14a3c652e9b5b67beb5d'; \ \ wget -O go.tgz.asc "$url.asc"; \ wget -O go.tgz "$url"; \ diff --git a/1.17-rc/buster/Dockerfile b/1.17/buster/Dockerfile similarity index 74% rename from 1.17-rc/buster/Dockerfile rename to 1.17/buster/Dockerfile index 281b7c8f..298872ba 100644 --- a/1.17-rc/buster/Dockerfile +++ b/1.17/buster/Dockerfile @@ -17,7 +17,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ ENV PATH /usr/local/go/bin:$PATH -ENV GOLANG_VERSION 1.17rc2 +ENV GOLANG_VERSION 1.17 RUN set -eux; \ \ @@ -25,34 +25,34 @@ RUN set -eux; \ url=; \ case "${dpkgArch##*-}" in \ 'amd64') \ - url='https://dl.google.com/go/go1.17rc2.linux-amd64.tar.gz'; \ - sha256='328235edc7c7d2a51d6c6cb4d7ff97e97357654ef9e1098b9a4603a9d278ad04'; \ + url='https://dl.google.com/go/go1.17.linux-amd64.tar.gz'; \ + sha256='6bf89fc4f5ad763871cf7eac80a2d594492de7a818303283f1366a7f6a30372d'; \ ;; \ 'armel') \ export GOARCH='arm' GOARM='5' GOOS='linux'; \ ;; \ 'armhf') \ - url='https://dl.google.com/go/go1.17rc2.linux-armv6l.tar.gz'; \ - sha256='4820fcd80b47e7d7dc1f15343c4fb59e66183cef9dadb3d3ac10f82615ad2141'; \ + url='https://dl.google.com/go/go1.17.linux-armv6l.tar.gz'; \ + sha256='ae89d33f4e4acc222bdb04331933d5ece4ae71039812f6ccd7493cb3e8ddfb4e'; \ ;; \ 'arm64') \ - url='https://dl.google.com/go/go1.17rc2.linux-arm64.tar.gz'; \ - sha256='4e1b335c53bf28cd20c5f7f2f7e79187b93e71c1d027448e313097785efb673d'; \ + url='https://dl.google.com/go/go1.17.linux-arm64.tar.gz'; \ + sha256='01a9af009ada22122d3fcb9816049c1d21842524b38ef5d5a0e2ee4b26d7c3e7'; \ ;; \ 'i386') \ - url='https://dl.google.com/go/go1.17rc2.linux-386.tar.gz'; \ - sha256='273fd4647d2311e3044d3d937eedbee91477317d867b6c81636fdc0a9ba7f947'; \ + url='https://dl.google.com/go/go1.17.linux-386.tar.gz'; \ + sha256='c19e3227a6ac6329db91d1af77bbf239ccd760a259c16e6b9c932d527ff14848'; \ ;; \ 'mips64el') \ export GOARCH='mips64le' GOOS='linux'; \ ;; \ 'ppc64el') \ - url='https://dl.google.com/go/go1.17rc2.linux-ppc64le.tar.gz'; \ - sha256='57fd15f97e4fccc3227d07423baca2b3e44fb2c1b12a35f8cda8a453867ca1b6'; \ + url='https://dl.google.com/go/go1.17.linux-ppc64le.tar.gz'; \ + sha256='ee84350114d532bf15f096198c675aafae9ff091dc4cc69eb49e1817ff94dbd7'; \ ;; \ 's390x') \ - url='https://dl.google.com/go/go1.17rc2.linux-s390x.tar.gz'; \ - sha256='be3a78ae162eac193fc66b0ed50f56c75c5a1506c6b631a1f2af3d4e700816fe'; \ + url='https://dl.google.com/go/go1.17.linux-s390x.tar.gz'; \ + sha256='a50aaecf054f393575f969a9105d5c6864dd91afc5287d772449033fbafcf7e3'; \ ;; \ *) echo >&2 "error: unsupported architecture '$dpkgArch' (likely packaging update needed)"; exit 1 ;; \ esac; \ @@ -60,8 +60,8 @@ RUN set -eux; \ if [ -z "$url" ]; then \ # https://github.com/golang/go/issues/38536#issuecomment-616897960 build=1; \ - url='https://dl.google.com/go/go1.17rc2.src.tar.gz'; \ - sha256='5ab21d75552390c63087518e4eba2972fb009aea97ff2bcc42dff264c5f46fe9'; \ + url='https://dl.google.com/go/go1.17.src.tar.gz'; \ + sha256='3a70e5055509f347c0fb831ca07a2bf3b531068f349b14a3c652e9b5b67beb5d'; \ echo >&2; \ echo >&2 "warning: current architecture ($dpkgArch) does not have a corresponding Go binary release; will be building from source"; \ echo >&2; \ diff --git a/1.17-rc/stretch/Dockerfile b/1.17/stretch/Dockerfile similarity index 74% rename from 1.17-rc/stretch/Dockerfile rename to 1.17/stretch/Dockerfile index 27e97e84..5c30f1a4 100644 --- a/1.17-rc/stretch/Dockerfile +++ b/1.17/stretch/Dockerfile @@ -17,7 +17,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ ENV PATH /usr/local/go/bin:$PATH -ENV GOLANG_VERSION 1.17rc2 +ENV GOLANG_VERSION 1.17 RUN set -eux; \ \ @@ -25,34 +25,34 @@ RUN set -eux; \ url=; \ case "${dpkgArch##*-}" in \ 'amd64') \ - url='https://dl.google.com/go/go1.17rc2.linux-amd64.tar.gz'; \ - sha256='328235edc7c7d2a51d6c6cb4d7ff97e97357654ef9e1098b9a4603a9d278ad04'; \ + url='https://dl.google.com/go/go1.17.linux-amd64.tar.gz'; \ + sha256='6bf89fc4f5ad763871cf7eac80a2d594492de7a818303283f1366a7f6a30372d'; \ ;; \ 'armel') \ export GOARCH='arm' GOARM='5' GOOS='linux'; \ ;; \ 'armhf') \ - url='https://dl.google.com/go/go1.17rc2.linux-armv6l.tar.gz'; \ - sha256='4820fcd80b47e7d7dc1f15343c4fb59e66183cef9dadb3d3ac10f82615ad2141'; \ + url='https://dl.google.com/go/go1.17.linux-armv6l.tar.gz'; \ + sha256='ae89d33f4e4acc222bdb04331933d5ece4ae71039812f6ccd7493cb3e8ddfb4e'; \ ;; \ 'arm64') \ - url='https://dl.google.com/go/go1.17rc2.linux-arm64.tar.gz'; \ - sha256='4e1b335c53bf28cd20c5f7f2f7e79187b93e71c1d027448e313097785efb673d'; \ + url='https://dl.google.com/go/go1.17.linux-arm64.tar.gz'; \ + sha256='01a9af009ada22122d3fcb9816049c1d21842524b38ef5d5a0e2ee4b26d7c3e7'; \ ;; \ 'i386') \ - url='https://dl.google.com/go/go1.17rc2.linux-386.tar.gz'; \ - sha256='273fd4647d2311e3044d3d937eedbee91477317d867b6c81636fdc0a9ba7f947'; \ + url='https://dl.google.com/go/go1.17.linux-386.tar.gz'; \ + sha256='c19e3227a6ac6329db91d1af77bbf239ccd760a259c16e6b9c932d527ff14848'; \ ;; \ 'mips64el') \ export GOARCH='mips64le' GOOS='linux'; \ ;; \ 'ppc64el') \ - url='https://dl.google.com/go/go1.17rc2.linux-ppc64le.tar.gz'; \ - sha256='57fd15f97e4fccc3227d07423baca2b3e44fb2c1b12a35f8cda8a453867ca1b6'; \ + url='https://dl.google.com/go/go1.17.linux-ppc64le.tar.gz'; \ + sha256='ee84350114d532bf15f096198c675aafae9ff091dc4cc69eb49e1817ff94dbd7'; \ ;; \ 's390x') \ - url='https://dl.google.com/go/go1.17rc2.linux-s390x.tar.gz'; \ - sha256='be3a78ae162eac193fc66b0ed50f56c75c5a1506c6b631a1f2af3d4e700816fe'; \ + url='https://dl.google.com/go/go1.17.linux-s390x.tar.gz'; \ + sha256='a50aaecf054f393575f969a9105d5c6864dd91afc5287d772449033fbafcf7e3'; \ ;; \ *) echo >&2 "error: unsupported architecture '$dpkgArch' (likely packaging update needed)"; exit 1 ;; \ esac; \ @@ -60,8 +60,8 @@ RUN set -eux; \ if [ -z "$url" ]; then \ # https://github.com/golang/go/issues/38536#issuecomment-616897960 build=1; \ - url='https://dl.google.com/go/go1.17rc2.src.tar.gz'; \ - sha256='5ab21d75552390c63087518e4eba2972fb009aea97ff2bcc42dff264c5f46fe9'; \ + url='https://dl.google.com/go/go1.17.src.tar.gz'; \ + sha256='3a70e5055509f347c0fb831ca07a2bf3b531068f349b14a3c652e9b5b67beb5d'; \ echo >&2; \ echo >&2 "warning: current architecture ($dpkgArch) does not have a corresponding Go binary release; will be building from source"; \ echo >&2; \ diff --git a/1.17-rc/windows/nanoserver-1809/Dockerfile b/1.17/windows/nanoserver-1809/Dockerfile similarity index 88% rename from 1.17-rc/windows/nanoserver-1809/Dockerfile rename to 1.17/windows/nanoserver-1809/Dockerfile index 8b7c2861..f919582e 100644 --- a/1.17-rc/windows/nanoserver-1809/Dockerfile +++ b/1.17/windows/nanoserver-1809/Dockerfile @@ -21,10 +21,10 @@ RUN setx /m PATH "%GOPATH%\bin;C:\Program Files\Go\bin;%PATH%" USER ContainerUser # doing this first to share cache across versions more aggressively -ENV GOLANG_VERSION 1.17rc2 +ENV GOLANG_VERSION 1.17 # Docker's Windows path parsing is absolutely *cursed*; please just trust me on this one -Tianon -COPY --from=golang:1.17rc2-windowsservercore-1809 ["C:\\\\Program Files\\\\Go","C:\\\\Program Files\\\\Go"] +COPY --from=golang:1.17-windowsservercore-1809 ["C:\\\\Program Files\\\\Go","C:\\\\Program Files\\\\Go"] RUN go version WORKDIR $GOPATH diff --git a/1.17-rc/windows/windowsservercore-1809/Dockerfile b/1.17/windows/windowsservercore-1809/Dockerfile similarity index 95% rename from 1.17-rc/windows/windowsservercore-1809/Dockerfile rename to 1.17/windows/windowsservercore-1809/Dockerfile index cddec563..f45ea71c 100644 --- a/1.17-rc/windows/windowsservercore-1809/Dockerfile +++ b/1.17/windows/windowsservercore-1809/Dockerfile @@ -53,13 +53,13 @@ RUN $newPath = ('{0}\bin;C:\Program Files\Go\bin;{1}' -f $env:GOPATH, $env:PATH) [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine); # doing this first to share cache across versions more aggressively -ENV GOLANG_VERSION 1.17rc2 +ENV GOLANG_VERSION 1.17 -RUN $url = 'https://dl.google.com/go/go1.17rc2.windows-amd64.zip'; \ +RUN $url = 'https://dl.google.com/go/go1.17.windows-amd64.zip'; \ Write-Host ('Downloading {0} ...' -f $url); \ Invoke-WebRequest -Uri $url -OutFile 'go.zip'; \ \ - $sha256 = '4b4d5aa3a393c3d633286053ffad08a2b2ae558a7ee09116014f42fccb12c753'; \ + $sha256 = '2a18bd65583e221be8b9b7c2fbe3696c40f6e27c2df689bbdcc939d49651d151'; \ Write-Host ('Verifying sha256 ({0}) ...' -f $sha256); \ if ((Get-FileHash go.zip -Algorithm sha256).Hash -ne $sha256) { \ Write-Host 'FAILED!'; \ diff --git a/1.17-rc/windows/windowsservercore-ltsc2016/Dockerfile b/1.17/windows/windowsservercore-ltsc2016/Dockerfile similarity index 95% rename from 1.17-rc/windows/windowsservercore-ltsc2016/Dockerfile rename to 1.17/windows/windowsservercore-ltsc2016/Dockerfile index 32fc88f8..7e0a5cd7 100644 --- a/1.17-rc/windows/windowsservercore-ltsc2016/Dockerfile +++ b/1.17/windows/windowsservercore-ltsc2016/Dockerfile @@ -53,13 +53,13 @@ RUN $newPath = ('{0}\bin;C:\Program Files\Go\bin;{1}' -f $env:GOPATH, $env:PATH) [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine); # doing this first to share cache across versions more aggressively -ENV GOLANG_VERSION 1.17rc2 +ENV GOLANG_VERSION 1.17 -RUN $url = 'https://dl.google.com/go/go1.17rc2.windows-amd64.zip'; \ +RUN $url = 'https://dl.google.com/go/go1.17.windows-amd64.zip'; \ Write-Host ('Downloading {0} ...' -f $url); \ Invoke-WebRequest -Uri $url -OutFile 'go.zip'; \ \ - $sha256 = '4b4d5aa3a393c3d633286053ffad08a2b2ae558a7ee09116014f42fccb12c753'; \ + $sha256 = '2a18bd65583e221be8b9b7c2fbe3696c40f6e27c2df689bbdcc939d49651d151'; \ Write-Host ('Verifying sha256 ({0}) ...' -f $sha256); \ if ((Get-FileHash go.zip -Algorithm sha256).Hash -ne $sha256) { \ Write-Host 'FAILED!'; \ diff --git a/generate-stackbrew-library.sh b/generate-stackbrew-library.sh index a285a289..1995b3a5 100755 --- a/generate-stackbrew-library.sh +++ b/generate-stackbrew-library.sh @@ -2,8 +2,8 @@ set -Eeuo pipefail declare -A aliases=( - [1.16]='1 latest' - [1.17-rc]='rc' + [1.17]='1 latest' + [1.18-rc]='rc' ) defaultDebianSuite='buster' diff --git a/versions.json b/versions.json index 4fceedbb..91e2e5d0 100644 --- a/versions.json +++ b/versions.json @@ -1,149 +1,4 @@ { - "1.15": { - "arches": { - "amd64": { - "env": { - "GOARCH": "amd64", - "GOOS": "linux" - }, - "sha256": "0885cf046a9f099e260d98d9ec5d19ea9328f34c8dc4956e1d3cd87daaddb345", - "supported": true, - "url": "https://dl.google.com/go/go1.15.15.linux-amd64.tar.gz" - }, - "arm32v5": { - "env": { - "GOARCH": "arm", - "GOARM": "5", - "GOOS": "linux" - }, - "supported": true - }, - "arm32v6": { - "env": { - "GOARCH": "arm", - "GOARM": "6", - "GOOS": "linux" - }, - "sha256": "7192603af50afb23c9d8cd14d2b2c19e0985a34d3eca685fa098df7893000d19", - "supported": true, - "url": "https://dl.google.com/go/go1.15.15.linux-armv6l.tar.gz" - }, - "arm32v7": { - "env": { - "GOARCH": "arm", - "GOARM": "7", - "GOOS": "linux" - }, - "sha256": "7192603af50afb23c9d8cd14d2b2c19e0985a34d3eca685fa098df7893000d19", - "supported": true, - "url": "https://dl.google.com/go/go1.15.15.linux-armv6l.tar.gz" - }, - "arm64v8": { - "env": { - "GOARCH": "arm64", - "GOOS": "linux" - }, - "sha256": "714abb01af210473dd6af331094ad6847162eff81a7fc7241d24f5a85496c9fa", - "supported": true, - "url": "https://dl.google.com/go/go1.15.15.linux-arm64.tar.gz" - }, - "darwin-amd64": { - "env": { - "GOARCH": "amd64", - "GOOS": "darwin" - }, - "sha256": "2f4c119524450ee94062a1ce7112fb88ce0fe4bb0303a302e002183a550c25c2", - "supported": false, - "url": "https://dl.google.com/go/go1.15.15.darwin-amd64.tar.gz" - }, - "freebsd-amd64": { - "env": { - "GOARCH": "amd64", - "GOOS": "freebsd" - }, - "sha256": "1f80a20419b2618182ef5b9615dd990b32b952d81b354b373c6fd304527bb70c", - "supported": false, - "url": "https://dl.google.com/go/go1.15.15.freebsd-amd64.tar.gz" - }, - "freebsd-i386": { - "env": { - "GOARCH": "386", - "GOOS": "freebsd" - }, - "sha256": "7174078a53e330cf351dc20bed6682033f44066d8aed754139bcaef52e53c214", - "supported": false, - "url": "https://dl.google.com/go/go1.15.15.freebsd-386.tar.gz" - }, - "i386": { - "env": { - "GO386": "387", - "GOARCH": "386", - "GOOS": "linux" - }, - "sha256": "3310fb0e48b0907bb520f6e3c6dcff63cc0913b92a76456f12980d0eb13b77d4", - "supported": true, - "url": "https://dl.google.com/go/go1.15.15.linux-386.tar.gz" - }, - "mips64le": { - "env": { - "GOARCH": "mips64le", - "GOOS": "linux" - }, - "supported": true - }, - "ppc64le": { - "env": { - "GOARCH": "ppc64le", - "GOOS": "linux" - }, - "sha256": "37f3b99e21d0324a6583159e14e42e57e56561abbf7bf68bef3d8f57b29e39c0", - "supported": true, - "url": "https://dl.google.com/go/go1.15.15.linux-ppc64le.tar.gz" - }, - "s390x": { - "env": { - "GOARCH": "s390x", - "GOOS": "linux" - }, - "sha256": "eae39d97df6b758636d5427be0b083dbf9d49007b302825ac6c8645de039aaab", - "supported": true, - "url": "https://dl.google.com/go/go1.15.15.linux-s390x.tar.gz" - }, - "src": { - "sha256": "0662ae3813330280d5f1a97a2ee23bbdbe3a5a7cfa6001b24a9873a19a0dc7ec", - "supported": true, - "url": "https://dl.google.com/go/go1.15.15.src.tar.gz" - }, - "windows-amd64": { - "env": { - "GOARCH": "amd64", - "GOOS": "windows" - }, - "sha256": "7df7bf948dcc8ec0a3902e3301d17cbb5c2ebb01297d686ee2302e41f4ac6e10", - "supported": true, - "url": "https://dl.google.com/go/go1.15.15.windows-amd64.zip" - }, - "windows-i386": { - "env": { - "GOARCH": "386", - "GOOS": "windows" - }, - "sha256": "4036abdeb36c7db380d05f3ffd087b754c34df06b202ee381da77f4c5a44aa58", - "supported": false, - "url": "https://dl.google.com/go/go1.15.15.windows-386.zip" - } - }, - "variants": [ - "buster", - "stretch", - "alpine3.14", - "alpine3.13", - "windows/windowsservercore-1809", - "windows/windowsservercore-ltsc2016", - "windows/nanoserver-1809" - ], - "version": "1.15.15" - }, "1.16": { "arches": { "amd64": { @@ -298,16 +153,16 @@ ], "version": "1.16.7" }, - "1.17-rc": { + "1.17": { "arches": { "amd64": { "env": { "GOARCH": "amd64", "GOOS": "linux" }, - "sha256": "328235edc7c7d2a51d6c6cb4d7ff97e97357654ef9e1098b9a4603a9d278ad04", + "sha256": "6bf89fc4f5ad763871cf7eac80a2d594492de7a818303283f1366a7f6a30372d", "supported": true, - "url": "https://dl.google.com/go/go1.17rc2.linux-amd64.tar.gz" + "url": "https://dl.google.com/go/go1.17.linux-amd64.tar.gz" }, "arm32v5": { "env": { @@ -323,9 +178,9 @@ "GOARM": "6", "GOOS": "linux" }, - "sha256": "4820fcd80b47e7d7dc1f15343c4fb59e66183cef9dadb3d3ac10f82615ad2141", + "sha256": "ae89d33f4e4acc222bdb04331933d5ece4ae71039812f6ccd7493cb3e8ddfb4e", "supported": true, - "url": "https://dl.google.com/go/go1.17rc2.linux-armv6l.tar.gz" + "url": "https://dl.google.com/go/go1.17.linux-armv6l.tar.gz" }, "arm32v7": { "env": { @@ -333,54 +188,54 @@ "GOARM": "7", "GOOS": "linux" }, - "sha256": "4820fcd80b47e7d7dc1f15343c4fb59e66183cef9dadb3d3ac10f82615ad2141", + "sha256": "ae89d33f4e4acc222bdb04331933d5ece4ae71039812f6ccd7493cb3e8ddfb4e", "supported": true, - "url": "https://dl.google.com/go/go1.17rc2.linux-armv6l.tar.gz" + "url": "https://dl.google.com/go/go1.17.linux-armv6l.tar.gz" }, "arm64v8": { "env": { "GOARCH": "arm64", "GOOS": "linux" }, - "sha256": "4e1b335c53bf28cd20c5f7f2f7e79187b93e71c1d027448e313097785efb673d", + "sha256": "01a9af009ada22122d3fcb9816049c1d21842524b38ef5d5a0e2ee4b26d7c3e7", "supported": true, - "url": "https://dl.google.com/go/go1.17rc2.linux-arm64.tar.gz" + "url": "https://dl.google.com/go/go1.17.linux-arm64.tar.gz" }, "darwin-amd64": { "env": { "GOARCH": "amd64", "GOOS": "darwin" }, - "sha256": "8abf0b17d6a0664e53ea7e1aecb649e2378732d2d97e8a292c27e6aae711c6c9", + "sha256": "355bd544ce08d7d484d9d7de05a71b5c6f5bc10aa4b316688c2192aeb3dacfd1", "supported": false, - "url": "https://dl.google.com/go/go1.17rc2.darwin-amd64.tar.gz" + "url": "https://dl.google.com/go/go1.17.darwin-amd64.tar.gz" }, "darwin-arm64v8": { "env": { "GOARCH": "arm64", "GOOS": "darwin" }, - "sha256": "fb8954dc8172bfabb8c22125a994a04278be554f15a1cb26ff2595841d9c1ba1", + "sha256": "da4e3e3c194bf9eed081de8842a157120ef44a7a8d7c820201adae7b0e28b20b", "supported": false, - "url": "https://dl.google.com/go/go1.17rc2.darwin-arm64.tar.gz" + "url": "https://dl.google.com/go/go1.17.darwin-arm64.tar.gz" }, "freebsd-amd64": { "env": { "GOARCH": "amd64", "GOOS": "freebsd" }, - "sha256": "48b36ed9618b81d4d59acdec3bcf56f18e97173c46dd5efa875ad7b03da61330", + "sha256": "15c184c83d99441d719da201b26256455eee85a808747c404b4183e9aa6c64b4", "supported": false, - "url": "https://dl.google.com/go/go1.17rc2.freebsd-amd64.tar.gz" + "url": "https://dl.google.com/go/go1.17.freebsd-amd64.tar.gz" }, "freebsd-i386": { "env": { "GOARCH": "386", "GOOS": "freebsd" }, - "sha256": "cffffb5dc4937d1f6728cc9a88aa33ade059040a3b3856eca8e65d31df3e3b49", + "sha256": "6819a7a11b8351d5d5768f2fff666abde97577602394f132cb7f85b3a7151f05", "supported": false, - "url": "https://dl.google.com/go/go1.17rc2.freebsd-386.tar.gz" + "url": "https://dl.google.com/go/go1.17.freebsd-386.tar.gz" }, "i386": { "env": { @@ -388,9 +243,9 @@ "GOARCH": "386", "GOOS": "linux" }, - "sha256": "273fd4647d2311e3044d3d937eedbee91477317d867b6c81636fdc0a9ba7f947", + "sha256": "c19e3227a6ac6329db91d1af77bbf239ccd760a259c16e6b9c932d527ff14848", "supported": true, - "url": "https://dl.google.com/go/go1.17rc2.linux-386.tar.gz" + "url": "https://dl.google.com/go/go1.17.linux-386.tar.gz" }, "mips64le": { "env": { @@ -404,50 +259,50 @@ "GOARCH": "ppc64le", "GOOS": "linux" }, - "sha256": "57fd15f97e4fccc3227d07423baca2b3e44fb2c1b12a35f8cda8a453867ca1b6", + "sha256": "ee84350114d532bf15f096198c675aafae9ff091dc4cc69eb49e1817ff94dbd7", "supported": true, - "url": "https://dl.google.com/go/go1.17rc2.linux-ppc64le.tar.gz" + "url": "https://dl.google.com/go/go1.17.linux-ppc64le.tar.gz" }, "s390x": { "env": { "GOARCH": "s390x", "GOOS": "linux" }, - "sha256": "be3a78ae162eac193fc66b0ed50f56c75c5a1506c6b631a1f2af3d4e700816fe", + "sha256": "a50aaecf054f393575f969a9105d5c6864dd91afc5287d772449033fbafcf7e3", "supported": true, - "url": "https://dl.google.com/go/go1.17rc2.linux-s390x.tar.gz" + "url": "https://dl.google.com/go/go1.17.linux-s390x.tar.gz" }, "src": { - "sha256": "5ab21d75552390c63087518e4eba2972fb009aea97ff2bcc42dff264c5f46fe9", + "sha256": "3a70e5055509f347c0fb831ca07a2bf3b531068f349b14a3c652e9b5b67beb5d", "supported": true, - "url": "https://dl.google.com/go/go1.17rc2.src.tar.gz" + "url": "https://dl.google.com/go/go1.17.src.tar.gz" }, "windows-amd64": { "env": { "GOARCH": "amd64", "GOOS": "windows" }, - "sha256": "4b4d5aa3a393c3d633286053ffad08a2b2ae558a7ee09116014f42fccb12c753", + "sha256": "2a18bd65583e221be8b9b7c2fbe3696c40f6e27c2df689bbdcc939d49651d151", "supported": true, - "url": "https://dl.google.com/go/go1.17rc2.windows-amd64.zip" + "url": "https://dl.google.com/go/go1.17.windows-amd64.zip" }, "windows-arm64v8": { "env": { "GOARCH": "arm64", "GOOS": "windows" }, - "sha256": "4de539dd74ca86cde5c2a21671ab88e301a5d7e63af30aedbf03cc7a2776cbd1", + "sha256": "5256f92f643d9022394ddc84de5c74fe8660c2151daaa199b12e60e542d694ae", "supported": false, - "url": "https://dl.google.com/go/go1.17rc2.windows-arm64.zip" + "url": "https://dl.google.com/go/go1.17.windows-arm64.zip" }, "windows-i386": { "env": { "GOARCH": "386", "GOOS": "windows" }, - "sha256": "c74a563ef59a8bdd0ee96d03c5dc4db21bf077d1f89dc2056d1c6d99de6ffed8", + "sha256": "c5afdd2ea4969f2b44637e913b04f7c15265d7beb60924a28063722670a52feb", "supported": false, - "url": "https://dl.google.com/go/go1.17rc2.windows-386.zip" + "url": "https://dl.google.com/go/go1.17.windows-386.zip" } }, "variants": [ @@ -459,6 +314,6 @@ "windows/windowsservercore-ltsc2016", "windows/nanoserver-1809" ], - "version": "1.17rc2" + "version": "1.17" } } From 48a7371ed6055a97a10adb0b75756192ad5f1c97 Mon Sep 17 00:00:00 2001 From: Tianon Gravi Date: Mon, 16 Aug 2021 14:55:39 -0700 Subject: [PATCH 2/2] Add bullseye variants --- 1.16/bullseye/Dockerfile | 123 ++++++++++++++++++++++++++++++++++ 1.17/bullseye/Dockerfile | 123 ++++++++++++++++++++++++++++++++++ generate-stackbrew-library.sh | 2 +- versions.json | 2 + versions.sh | 1 + 5 files changed, 250 insertions(+), 1 deletion(-) create mode 100644 1.16/bullseye/Dockerfile create mode 100644 1.17/bullseye/Dockerfile diff --git a/1.16/bullseye/Dockerfile b/1.16/bullseye/Dockerfile new file mode 100644 index 00000000..e80e81e9 --- /dev/null +++ b/1.16/bullseye/Dockerfile @@ -0,0 +1,123 @@ +# +# NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" +# +# PLEASE DO NOT EDIT IT DIRECTLY. +# + +FROM buildpack-deps:bullseye-scm + +# gcc for cgo +RUN apt-get update && apt-get install -y --no-install-recommends \ + g++ \ + gcc \ + libc6-dev \ + make \ + pkg-config \ + && rm -rf /var/lib/apt/lists/* + +ENV PATH /usr/local/go/bin:$PATH + +ENV GOLANG_VERSION 1.16.7 + +RUN set -eux; \ + \ + dpkgArch="$(dpkg --print-architecture)"; \ + url=; \ + case "${dpkgArch##*-}" in \ + 'amd64') \ + url='https://dl.google.com/go/go1.16.7.linux-amd64.tar.gz'; \ + sha256='7fe7a73f55ba3e2285da36f8b085e5c0159e9564ef5f63ee0ed6b818ade8ef04'; \ + ;; \ + 'armel') \ + export GOARCH='arm' GOARM='5' GOOS='linux'; \ + ;; \ + 'armhf') \ + url='https://dl.google.com/go/go1.16.7.linux-armv6l.tar.gz'; \ + sha256='b2973ceeae234866368baf9469fb7b9444857e50dc785ba879d98a0aa208a12b'; \ + ;; \ + 'arm64') \ + url='https://dl.google.com/go/go1.16.7.linux-arm64.tar.gz'; \ + sha256='63d6b53ecbd2b05c1f0e9903c92042663f2f68afdbb67f4d0d12700156869bac'; \ + ;; \ + 'i386') \ + url='https://dl.google.com/go/go1.16.7.linux-386.tar.gz'; \ + sha256='5c0c8891fa88993f2193fbc9dd5cca6c250c89aa8c12bbaa382b6ff38139bcc3'; \ + ;; \ + 'mips64el') \ + export GOARCH='mips64le' GOOS='linux'; \ + ;; \ + 'ppc64el') \ + url='https://dl.google.com/go/go1.16.7.linux-ppc64le.tar.gz'; \ + sha256='03e02b2ac6dc1601203f335385b9bbe15a55677066d9a1a1280b5fcfa6ec4738'; \ + ;; \ + 's390x') \ + url='https://dl.google.com/go/go1.16.7.linux-s390x.tar.gz'; \ + sha256='5f691c9551710ebb17bbda04389944aa7332f42ab28f92516a69fbd7860e7e9f'; \ + ;; \ + *) echo >&2 "error: unsupported architecture '$dpkgArch' (likely packaging update needed)"; exit 1 ;; \ + esac; \ + build=; \ + if [ -z "$url" ]; then \ +# https://github.com/golang/go/issues/38536#issuecomment-616897960 + build=1; \ + url='https://dl.google.com/go/go1.16.7.src.tar.gz'; \ + sha256='1a9f2894d3d878729f7045072f30becebe243524cf2fce4e0a7b248b1e0654ac'; \ + echo >&2; \ + echo >&2 "warning: current architecture ($dpkgArch) does not have a corresponding Go binary release; will be building from source"; \ + echo >&2; \ + fi; \ + \ + wget -O go.tgz.asc "$url.asc" --progress=dot:giga; \ + wget -O go.tgz "$url" --progress=dot:giga; \ + echo "$sha256 *go.tgz" | sha256sum --strict --check -; \ + \ +# https://github.com/golang/go/issues/14739#issuecomment-324767697 + export GNUPGHOME="$(mktemp -d)"; \ +# https://www.google.com/linuxrepositories/ + gpg --batch --keyserver keyserver.ubuntu.com --recv-keys 'EB4C 1BFD 4F04 2F6D DDCC EC91 7721 F63B D38B 4796'; \ + gpg --batch --verify go.tgz.asc go.tgz; \ + gpgconf --kill all; \ + rm -rf "$GNUPGHOME" go.tgz.asc; \ + \ + tar -C /usr/local -xzf go.tgz; \ + rm go.tgz; \ + \ + if [ -n "$build" ]; then \ + savedAptMark="$(apt-mark showmanual)"; \ + apt-get update; \ + apt-get install -y --no-install-recommends golang-go; \ + \ + ( \ + cd /usr/local/go/src; \ +# set GOROOT_BOOTSTRAP + GOHOST* such that we can build Go successfully + export GOROOT_BOOTSTRAP="$(go env GOROOT)" GOHOSTOS="$GOOS" GOHOSTARCH="$GOARCH"; \ + ./make.bash; \ + ); \ + \ + apt-mark auto '.*' > /dev/null; \ + apt-mark manual $savedAptMark > /dev/null; \ + apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ + rm -rf /var/lib/apt/lists/*; \ + \ +# pre-compile the standard library, just like the official binary release tarballs do + go install std; \ +# go install: -race is only supported on linux/amd64, linux/ppc64le, linux/arm64, freebsd/amd64, netbsd/amd64, darwin/amd64 and windows/amd64 +# go install -race std; \ + \ +# remove a few intermediate / bootstrapping files the official binary release tarballs do not contain + rm -rf \ + /usr/local/go/pkg/*/cmd \ + /usr/local/go/pkg/bootstrap \ + /usr/local/go/pkg/obj \ + /usr/local/go/pkg/tool/*/api \ + /usr/local/go/pkg/tool/*/go_bootstrap \ + /usr/local/go/src/cmd/dist/dist \ + ; \ + fi; \ + \ + go version + +ENV GOPATH /go +ENV PATH $GOPATH/bin:$PATH +RUN mkdir -p "$GOPATH/src" "$GOPATH/bin" && chmod -R 777 "$GOPATH" +WORKDIR $GOPATH diff --git a/1.17/bullseye/Dockerfile b/1.17/bullseye/Dockerfile new file mode 100644 index 00000000..ef0e425f --- /dev/null +++ b/1.17/bullseye/Dockerfile @@ -0,0 +1,123 @@ +# +# NOTE: THIS DOCKERFILE IS GENERATED VIA "apply-templates.sh" +# +# PLEASE DO NOT EDIT IT DIRECTLY. +# + +FROM buildpack-deps:bullseye-scm + +# gcc for cgo +RUN apt-get update && apt-get install -y --no-install-recommends \ + g++ \ + gcc \ + libc6-dev \ + make \ + pkg-config \ + && rm -rf /var/lib/apt/lists/* + +ENV PATH /usr/local/go/bin:$PATH + +ENV GOLANG_VERSION 1.17 + +RUN set -eux; \ + \ + dpkgArch="$(dpkg --print-architecture)"; \ + url=; \ + case "${dpkgArch##*-}" in \ + 'amd64') \ + url='https://dl.google.com/go/go1.17.linux-amd64.tar.gz'; \ + sha256='6bf89fc4f5ad763871cf7eac80a2d594492de7a818303283f1366a7f6a30372d'; \ + ;; \ + 'armel') \ + export GOARCH='arm' GOARM='5' GOOS='linux'; \ + ;; \ + 'armhf') \ + url='https://dl.google.com/go/go1.17.linux-armv6l.tar.gz'; \ + sha256='ae89d33f4e4acc222bdb04331933d5ece4ae71039812f6ccd7493cb3e8ddfb4e'; \ + ;; \ + 'arm64') \ + url='https://dl.google.com/go/go1.17.linux-arm64.tar.gz'; \ + sha256='01a9af009ada22122d3fcb9816049c1d21842524b38ef5d5a0e2ee4b26d7c3e7'; \ + ;; \ + 'i386') \ + url='https://dl.google.com/go/go1.17.linux-386.tar.gz'; \ + sha256='c19e3227a6ac6329db91d1af77bbf239ccd760a259c16e6b9c932d527ff14848'; \ + ;; \ + 'mips64el') \ + export GOARCH='mips64le' GOOS='linux'; \ + ;; \ + 'ppc64el') \ + url='https://dl.google.com/go/go1.17.linux-ppc64le.tar.gz'; \ + sha256='ee84350114d532bf15f096198c675aafae9ff091dc4cc69eb49e1817ff94dbd7'; \ + ;; \ + 's390x') \ + url='https://dl.google.com/go/go1.17.linux-s390x.tar.gz'; \ + sha256='a50aaecf054f393575f969a9105d5c6864dd91afc5287d772449033fbafcf7e3'; \ + ;; \ + *) echo >&2 "error: unsupported architecture '$dpkgArch' (likely packaging update needed)"; exit 1 ;; \ + esac; \ + build=; \ + if [ -z "$url" ]; then \ +# https://github.com/golang/go/issues/38536#issuecomment-616897960 + build=1; \ + url='https://dl.google.com/go/go1.17.src.tar.gz'; \ + sha256='3a70e5055509f347c0fb831ca07a2bf3b531068f349b14a3c652e9b5b67beb5d'; \ + echo >&2; \ + echo >&2 "warning: current architecture ($dpkgArch) does not have a corresponding Go binary release; will be building from source"; \ + echo >&2; \ + fi; \ + \ + wget -O go.tgz.asc "$url.asc" --progress=dot:giga; \ + wget -O go.tgz "$url" --progress=dot:giga; \ + echo "$sha256 *go.tgz" | sha256sum --strict --check -; \ + \ +# https://github.com/golang/go/issues/14739#issuecomment-324767697 + export GNUPGHOME="$(mktemp -d)"; \ +# https://www.google.com/linuxrepositories/ + gpg --batch --keyserver keyserver.ubuntu.com --recv-keys 'EB4C 1BFD 4F04 2F6D DDCC EC91 7721 F63B D38B 4796'; \ + gpg --batch --verify go.tgz.asc go.tgz; \ + gpgconf --kill all; \ + rm -rf "$GNUPGHOME" go.tgz.asc; \ + \ + tar -C /usr/local -xzf go.tgz; \ + rm go.tgz; \ + \ + if [ -n "$build" ]; then \ + savedAptMark="$(apt-mark showmanual)"; \ + apt-get update; \ + apt-get install -y --no-install-recommends golang-go; \ + \ + ( \ + cd /usr/local/go/src; \ +# set GOROOT_BOOTSTRAP + GOHOST* such that we can build Go successfully + export GOROOT_BOOTSTRAP="$(go env GOROOT)" GOHOSTOS="$GOOS" GOHOSTARCH="$GOARCH"; \ + ./make.bash; \ + ); \ + \ + apt-mark auto '.*' > /dev/null; \ + apt-mark manual $savedAptMark > /dev/null; \ + apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ + rm -rf /var/lib/apt/lists/*; \ + \ +# pre-compile the standard library, just like the official binary release tarballs do + go install std; \ +# go install: -race is only supported on linux/amd64, linux/ppc64le, linux/arm64, freebsd/amd64, netbsd/amd64, darwin/amd64 and windows/amd64 +# go install -race std; \ + \ +# remove a few intermediate / bootstrapping files the official binary release tarballs do not contain + rm -rf \ + /usr/local/go/pkg/*/cmd \ + /usr/local/go/pkg/bootstrap \ + /usr/local/go/pkg/obj \ + /usr/local/go/pkg/tool/*/api \ + /usr/local/go/pkg/tool/*/go_bootstrap \ + /usr/local/go/src/cmd/dist/dist \ + ; \ + fi; \ + \ + go version + +ENV GOPATH /go +ENV PATH $GOPATH/bin:$PATH +RUN mkdir -p "$GOPATH/src" "$GOPATH/bin" && chmod -R 777 "$GOPATH" +WORKDIR $GOPATH diff --git a/generate-stackbrew-library.sh b/generate-stackbrew-library.sh index 1995b3a5..7b903805 100755 --- a/generate-stackbrew-library.sh +++ b/generate-stackbrew-library.sh @@ -6,7 +6,7 @@ declare -A aliases=( [1.18-rc]='rc' ) -defaultDebianSuite='buster' +defaultDebianSuite='bullseye' declare -A debianSuite=( #[1.13-rc]='buster' ) diff --git a/versions.json b/versions.json index 91e2e5d0..471e2376 100644 --- a/versions.json +++ b/versions.json @@ -143,6 +143,7 @@ } }, "variants": [ + "bullseye", "buster", "stretch", "alpine3.14", @@ -306,6 +307,7 @@ } }, "variants": [ + "bullseye", "buster", "stretch", "alpine3.14", diff --git a/versions.sh b/versions.sh index a319a36a..626072d1 100755 --- a/versions.sh +++ b/versions.sh @@ -138,6 +138,7 @@ for version in "${versions[@]}"; do version: .version, arches: .arches, variants: [ + "bullseye", "buster", "stretch", (