De-configure sumdb and go proxy

This commit is contained in:
Jakub Čajka 2019-07-24 01:35:09 +02:00
parent f80e5ff991
commit 29d5602b19
2 changed files with 54 additions and 1 deletions

View File

@ -0,0 +1,48 @@
From 014cbe9e8cdc1a5f78f3e792309133eaaabdfc8f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jakub=20=C4=8Cajka?= <jcajka@redhat.com>
Date: Mon, 27 May 2019 15:12:53 +0200
Subject: [PATCH 3/3] cmd/go: disable Google's proxy and sumdb
---
src/cmd/go/internal/cfg/cfg.go | 4 ++--
src/cmd/go/testdata/script/mod_sumdb_golang.txt | 6 +++---
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/cmd/go/internal/cfg/cfg.go b/src/cmd/go/internal/cfg/cfg.go
index a0b51a72c3..b972a81df2 100644
--- a/src/cmd/go/internal/cfg/cfg.go
+++ b/src/cmd/go/internal/cfg/cfg.go
@@ -292,8 +292,8 @@ var (
GOPPC64 = envOr("GOPPC64", fmt.Sprintf("%s%d", "power", objabi.GOPPC64))
GOWASM = envOr("GOWASM", fmt.Sprint(objabi.GOWASM))
- GOPROXY = envOr("GOPROXY", "https://proxy.golang.org,direct")
- GOSUMDB = envOr("GOSUMDB", "sum.golang.org")
+ GOPROXY = envOr("GOPROXY", "direct")
+ GOSUMDB = envOr("GOSUMDB", "off")
GOPRIVATE = Getenv("GOPRIVATE")
GONOPROXY = envOr("GONOPROXY", GOPRIVATE)
GONOSUMDB = envOr("GONOSUMDB", GOPRIVATE)
diff --git a/src/cmd/go/testdata/script/mod_sumdb_golang.txt b/src/cmd/go/testdata/script/mod_sumdb_golang.txt
index 40a07fc7e9..50436e32d7 100644
--- a/src/cmd/go/testdata/script/mod_sumdb_golang.txt
+++ b/src/cmd/go/testdata/script/mod_sumdb_golang.txt
@@ -2,12 +2,12 @@
env GOPROXY=
env GOSUMDB=
go env GOPROXY
-stdout '^https://proxy.golang.org,direct$'
+stdout '^direct$'
go env GOSUMDB
-stdout '^sum.golang.org$'
+stdout '^off$'
env GOPROXY=https://proxy.golang.org
go env GOSUMDB
-stdout '^sum.golang.org$'
+stdout '^off$'
# download direct from github
[!net] skip
--
2.21.0

View File

@ -106,7 +106,7 @@
Name: golang
Version: 1.13
Release: 0.beta1.1%{?dist}
Release: 0.beta1.2%{?dist}
Summary: The Go Programming Language
# source tree includes several copies of Mark.Twain-Tom.Sawyer.txt under Public Domain
License: BSD and Public Domain
@ -183,6 +183,7 @@ Requires: go-srpm-macros
Patch1: 0001-Don-t-use-the-bundled-tzdata-at-runtime-except-for-t.patch
Patch2: 0002-syscall-expose-IfInfomsg.X__ifi_pad-on-s390x.patch
Patch3: 0003-cmd-go-disable-Google-s-proxy-and-sumdb.patch
# Having documentation separate was broken
Obsoletes: %{name}-docs < 1.1-4
@ -308,6 +309,7 @@ Requires: %{name} = %{version}-%{release}
%patch1 -p1
%patch2 -p1
%patch3 -p1
cp %{SOURCE1} ./src/runtime/
@ -546,6 +548,9 @@ fi
%endif
%changelog
* Wed Jul 24 2019 Jakub Čajka <jcajka@redhat.com> - 1.13-0.beta1.2
- De-configure sumdb and go proxy
* Wed Jul 24 2019 Jakub Čajka <jcajka@redhat.com> - 1.13-0.beta1.1
- Rebase to 1.13beta1
- Related: BZ#1732118