go.toolchain.rev: use new statically built toolchain

Also removes the toolchain builds from flake.nix. For now the flake
build uses upstream Go 1.20, a followup change will switch it back to
our custom toolchain.

Updates tailscale/corp#9005

Signed-off-by: David Anderson <danderson@tailscale.com>
This commit is contained in:
David Anderson
2023-02-02 19:37:32 -08:00
committed by Dave Anderson
parent 2dc3dc21a8
commit 02a2dcfc86
10 changed files with 12 additions and 75 deletions

View File

@ -58,14 +58,7 @@ get_cached() {
rm -f "$archive.new" "$TOOLCHAIN.extracted"
if [ ! -e "$archive" ]; then
log "Need to download go '$REV'."
if [ "$ARCH" = "amd64" ]; then
# For historic reasons, the tailscale/go amd64 release artifacts don't
# have the arch in their name.
BUILD="$GOOS"
else
BUILD="$GOOS-$ARCH"
fi
curl -f -L -o "$archive.new" "https://github.com/tailscale/go/releases/download/build-${REV}/${BUILD}.tar.gz"
curl -f -L -o "$archive.new" "https://github.com/tailscale/go/releases/download/build-${REV}/${GOOS}-${ARCH}.tar.gz"
rm -f "$archive"
mv "$archive.new" "$archive"
fi