Граф коммитов

1371 Коммитов

Автор SHA1 Сообщение Дата
Alexander Rakoczy 024bd71c08 cmd/release: install Go to appropriate Program Files directory
The previous default installation path, C:\Go, has default permissions
that are too permissive when adding a directory to the OS path. This
change moves the default installation target to "Program Files" or
"Program Files (x86)", which will inherit appropriate permissions, and
is the canonical place to install software on Windows.

Tested signed windows-386 and windows-amd64 artifacts on a 64-bit
Windows device.

Fixes golang/go#42070

Change-Id: I4a4cf744e53bb8f75b53d0f918de1707c4847882
Reviewed-on: https://go-review.googlesource.com/c/build/+/283600
Trust: Alexander Rakoczy <alex@golang.org>
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2021-01-20 19:49:02 +00:00
Dmitri Shuralyov 789b9298d8 cmd/updatestd: add experimental program to maintain standard library
We need to update dependencies vendored into the standard library at
least two times during each major Go release cycle, which is tracked
by the recurring release-blocker issue golang.org/issue/36905.

Once we find agreement on the overall strategy to do this, it will be
easier, more reliable, and more scalable to do with a program than by
hand. This experimental program serves as a starting point to get there.
It has been used to generate CL 255860 and CL 266898 so far, and more
to explore the state of changes to vendored golang.org/x packages at
tip. Code review has identified opportunities for improvement, which
was filed as an issue. Upon further investigation, it was found that
those improvements are not viable to use in the short term (see
https://golang.org/issue/41589#issuecomment-712965746), but perhaps
will be worth revisiting in the future.

The scope of update performed at this time is to update golang.org/x
modules dependencies inside the standard library, re-run go generate
-run=bundle task, and update the Go language version in go.mod files.
It's expected this will evolve over time based on experience and new
findings.

For golang/go#36905.
For golang/go#41409.

Change-Id: I0e9d42675f1d8300f661545625f3b20e3704cdca
Reviewed-on: https://go-review.googlesource.com/c/build/+/256357
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Trust: Dmitri Shuralyov <dmitshur@golang.org>
Trust: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2021-01-09 00:46:47 +00:00
Dmitri Shuralyov 4682f4add6 cmd/releasebot, cmd/release: add darwin-arm64 target for Go 1.16
For golang/go#42756.

Change-Id: Ia28fb6878617715fb674ccfad0c5801c8925270b
Reviewed-on: https://go-review.googlesource.com/c/build/+/278436
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Trust: Dmitri Shuralyov <dmitshur@golang.org>
2020-12-16 23:36:47 +00:00
Dmitri Shuralyov b0441a6af4 cmd/release: update checkRelocations for Go 1.16
The plan in https://golang.org/issue/40561#issuecomment-731482962
involved updating the linux-amd64 target from Debian Jessie to
Debian Stretch, which in turn comes with a newer version of GCC.

checkRelocations was added in CL 171317 in response to a bad minor
release that was accidentally issued without the intended fix, and
needs to be updated for Go 1.16 and newer releases. It's not clear
if we want to maintain it indefinitely for future Go versions, but
keep it for a bit longer. Add a note to make it clear that it can
be removed as needed in the future.

For golang/go#40561.
Updates golang/go#31293.

Change-Id: I2da419eff6379575eb2648787f0dac6bba07b304
Reviewed-on: https://go-review.googlesource.com/c/build/+/278357
Trust: Dmitri Shuralyov <dmitshur@golang.org>
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-12-15 21:38:44 +00:00
Julie Qiu 7ff1f9441a all: add or change GoDoc badge to pkg.go.dev manually
READMEs with a GoDoc badge that were not changed by update-readmes.go
are manually changed.

For golang/go#42251

Change-Id: Iaaa815e4a5f0905cfb20ea62fcb4cf2e75fde991
Reviewed-on: https://go-review.googlesource.com/c/build/+/276033
Trust: Julie Qiu <julie@golang.org>
Run-TryBot: Julie Qiu <julie@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-12-15 04:54:49 +00:00
Julie Qiu a56ae9428e all: add or change GoDoc badge to pkg.go.dev with update-readmes.go
update-readmes.go is updated to add a pkg.go.dev badge instead of a
godoc.org badge.

The GoDoc badge is added or changed in all READMEs by running
update-readmes.go

For golang/go#42251

Change-Id: I0c49df26a6c695f938c98c9a7b26325d991b3cfb
Reviewed-on: https://go-review.googlesource.com/c/build/+/276032
Trust: Julie Qiu <julie@golang.org>
Run-TryBot: Julie Qiu <julie@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-12-15 04:52:31 +00:00
Dmitri Shuralyov 90d5e7c418 cmd/release, dashboard: implement builder plan for Go 1.16
See https://golang.org/issues/40561#issuecomment-731482962
for the plan description and rationale.

Add new builder definitions that are needed for the plan.
Don't rely on generic builder name like "linux-amd64" to
avoid a repeat of golang.org/issue/31293; use a specific
builder name instead.

Remove support and test cases for Go 1.13, it's unsupported
per release policy.

For golang/go#40561.

Change-Id: I070744e15be9f1932d649a27ee7e4599e467553f
Reviewed-on: https://go-review.googlesource.com/c/build/+/276034
Trust: Dmitri Shuralyov <dmitshur@golang.org>
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-12-09 04:57:37 +00:00
Dmitri Shuralyov 4ab6ffe488 cmd/relnote: use Gerrit API to find RELNOTE markers in inline comments
Also filter out CLs on development or release branches.

Fixes golang/go#41849.

Change-Id: Ie6da4356d5f323dc15bd31b396889bfbf550d30b
Reviewed-on: https://go-review.googlesource.com/c/build/+/272907
Trust: Dmitri Shuralyov <dmitshur@golang.org>
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-12-01 17:57:49 +00:00
Dmitri Shuralyov 20e7ccc701 cmd/relnote: use GerritCL.Subject method instead of clSubject function
Apply a trivial code simplification. Tested by re-running relnote, and
its output did not change.

For golang/go#41849.

Change-Id: Ifffebca5ee55d7470f32a2469b4e41d1a1a458d1
Reviewed-on: https://go-review.googlesource.com/c/build/+/272906
Trust: Dmitri Shuralyov <dmitshur@golang.org>
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-12-01 17:57:11 +00:00
Jason A. Donenfeld 5d75ed716d dashboard: add new Windows ARM builder
This partially reverts CL 229559, while adjusting it to use a new
builder. The builder will be used now for windows/arm and later for
windows/arm64.

Updates golang/go#42604.
Updates golang/go#38607.
Updates golang/go#36439.

Change-Id: I1ab661a6585e64de8196955c077715b32dc732b8
Reviewed-on: https://go-review.googlesource.com/c/build/+/272106
Run-TryBot: Jason A. Donenfeld <Jason@zx2c4.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Trust: Alex Brainman <alex.brainman@gmail.com>
Trust: Jason A. Donenfeld <Jason@zx2c4.com>
2020-11-21 08:19:53 +00:00
Ian Lance Taylor 5f1e306b98 cmd/coordinator: add blank line before SlowBot message
Avoids a problem seen on https://golang.org/cl/269799:

Consult https://build.golang.org/ to see whether they are new failures. Keep in mind that TryBots currently test *exactly* your git commit, without rebasing. If your commit's git parent is old, the failure might've already been fixed.SlowBot builds that ran:

linux-ppc64-buildlet
linux-ppc64le-buildlet

Note that "Slowbot builds" is hidden at the end of the failure message.

Also slightly clean up the code: numFail is the length of a slice, and
can't be negative.

Change-Id: Id9c160dbb7031d75232df54b8662c94b2ce464b6
Reviewed-on: https://go-review.googlesource.com/c/build/+/269919
Trust: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-11-13 16:46:03 +00:00
Carlos Amedee d72655cc59 env/linux-arm/aws, dashboard: add linux-arm-aws builder
This change adds the linux-arm-aws builder. This builder will be
started on a EC2 instance which will spawn a single instance
of the container. After the builder work is done, the instance will be
destroyed.

Updates golang/go#41867

Change-Id: I09d911c2f99d1dff8fe02feb458457e07e7d0cdd
Reviewed-on: https://go-review.googlesource.com/c/build/+/260797
Trust: Carlos Amedee <carlos@golang.org>
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-11-09 20:12:59 +00:00
Carlos Amedee 725674f5ab internal/cloud, cmd/coordinator: add a rate limiter for the AWS client
This change adds an optional rate limiter which implements both rate
and resource limits. This change should enable the coordinator to add
additional builders hosted on EC2. This change will reduce the chance
that we encounter one of the limits.

The rate limiter is essential for any calls which mutate cloud
resources. While the EC2 client.DefaultRetryer should be sufficient
enough to handle the non-mutating requests, it would implement a best
practice in having client side rate limiting for those types of requests.

Amazon EC2 throttles requests EC2 API requests
https://docs.aws.amazon.com/AWSEC2/latest/APIReference/throttling.html

Fixes golang/go#40950

Change-Id: Ib80bcf7c5ab0b0483d5beb11f3581cdb1d0174fe
Reviewed-on: https://go-review.googlesource.com/c/build/+/267901
Trust: Carlos Amedee <carlos@golang.org>
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-11-09 20:12:48 +00:00
Aaron Bieber a3ef944b51 cmd/racebuild: add OpenBSD platform
As part of CL 237057. The race builder needs to know how to build the
.syso files on OpenBSD.

Updates golang/go#39464.

Change-Id: I71974e924801544be20be44c453bd3bc982443d6
GitHub-Last-Rev: 239f7d2800
GitHub-Pull-Request: golang/build#31
Reviewed-on: https://go-review.googlesource.com/c/build/+/239499
Reviewed-by: Keith Randall <khr@golang.org>
Reviewed-by: Joel Sing <joel@sing.id.au>
Trust: Joel Sing <joel@sing.id.au>
Run-TryBot: Keith Randall <khr@golang.org>
2020-11-09 16:40:11 +00:00
Dmitri Shuralyov 1a4bcd60cd cmd/coordinator: use corresponding Go for x repo release branch with suffix
When a golang.org/x repo release branch is being tested, the intention
is to test it with the same Go version where it will be used, rather
than the latest Go version in development plus prior releases of Go.

The previous equality check was very strict and did not work for
golang.org/x release branches with a dash-separated suffix. We have
a need for such release branches occasionally and want them to work.

Fixes golang/go#42127.

Change-Id: I934b540f83a2b8c616e3d3a5477fb3c471aa595b
Reviewed-on: https://go-review.googlesource.com/c/build/+/264203
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Trust: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-10-22 17:07:56 +00:00
Dmitri Shuralyov dc0a748d9c cmd/release: adjust comment to not begin with "// +build"
For golang/go#42019.

Change-Id: I5c47bff63f02785ad6cf0ee547e53e503a600601
Reviewed-on: https://go-review.googlesource.com/c/build/+/263117
Trust: Dmitri Shuralyov <dmitshur@golang.org>
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Joel Sing <joel@sing.id.au>
TryBot-Result: Go Bot <gobot@golang.org>
2020-10-16 16:16:08 +00:00
Dmitri Shuralyov f2cf9918e8 cmd/relnote: include closing dd tags in HTML output
In HTML5, closing dd tags are optional, meaning it is okay to either
include them or exclude them. For the purpose of writing the release
notes HTML file, which involves many people collaborating, it's less
costly to always include optional HTML tags.

This can eliminate the need for doing so manually, like in CL 217701,
CL 245979, and so on.

Change-Id: Idc16ea61e2b9624d1aa48543df2b913936993909
Reviewed-on: https://go-review.googlesource.com/c/build/+/260497
Trust: Dmitri Shuralyov <dmitshur@golang.org>
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-10-09 18:35:30 +00:00
Dmitri Shuralyov 0ff219384d dashboard, env/linux-x86-nacl: remove nacl builders and supporting files
Go 1.13 was the last release with nacl, and it's not supported by now.

For golang/go#30439.

Change-Id: Ic690aa388ab4505d5e755bbe40fed850a7300c69
Reviewed-on: https://go-review.googlesource.com/c/build/+/260200
Trust: Dmitri Shuralyov <dmitshur@golang.org>
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-10-08 14:56:23 +00:00
Hana (Hyang-Ah) Kim d1ab7ac8e2 cmd/gopherbot: rename a function to be more descriptive
labelChangeDisallowed is closer to what this function is meant for.

Change-Id: I64b143263df2d3dca018f9daecd73c2be59e84c9
Reviewed-on: https://go-review.googlesource.com/c/build/+/260417
Trust: Hyang-Ah Hana Kim <hyangah@gmail.com>
Run-TryBot: Hyang-Ah Hana Kim <hyangah@gmail.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-10-07 20:08:45 +00:00
Elias Naur a9f75ee999 cmd/buildlet: fix bash wrapper check for iOS
Updates golang/go#41610

Change-Id: I9a2e151eaf8104e2f3a1a8d36f8dc72a6351fd4a
Reviewed-on: https://go-review.googlesource.com/c/build/+/259580
Trust: Elias Naur <mail@eliasnaur.com>
Run-TryBot: Elias Naur <mail@eliasnaur.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-10-06 16:47:21 +00:00
Alexander Rakoczy 034e344671 cmd/relui: publish task start message to pubsub
This change adds a new handler for starting a task by sending a message
to pubsub. A test pubsub server is used in unit testing. The exact
message used to start a task, as well as updating a task to mark it as
started, is still under design and likely to change dramatically. This
change is intended to unblock worker development.

For golang/go#40279

Co-authored-by: Carlos Amedee <carlos@golang.org>
Change-Id: I59bb5c5261a9a5d17e52597c1835a2a980cf91f8
Reviewed-on: https://go-review.googlesource.com/c/build/+/257239
Trust: Alexander Rakoczy <alex@golang.org>
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-09-25 21:44:07 +00:00
Alexander Rakoczy a815a97c15 cmd/relui: generate uuid for workflow and task instances
Sets workflow and tasks IDs when a workflow is created in the UI. These
IDs will be used in the future when operating on workflows and tasks via
the UI or API.

This ID will likely change to a datastore ID after datastore integration
is added.

For golang/go#40279

Co-authored-by: Carlos Amedee <carlos@golang.org>
Change-Id: Ib75c00c234d156cc1bbdab8c658281f04914165b
Reviewed-on: https://go-review.googlesource.com/c/build/+/257238
Trust: Alexander Rakoczy <alex@golang.org>
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-09-25 20:12:48 +00:00
Alexander Rakoczy fac8f1ee5b cmd/relui: create pubsub topic on start
This will create and connect to a pubsub topic for communicating with
relui workers on application start. If the topic already exists, it will
just get a reference to the topic.

For golang/go#40279

Co-authored-by: Carlos Amedee <carlos@golang.org>
Change-Id: Ic173212cd15562b9d1a1cc601d307d5ee1a4e811
Reviewed-on: https://go-review.googlesource.com/c/build/+/257237
Trust: Alexander Rakoczy <alex@golang.org>
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-09-25 20:12:21 +00:00
Carlos Amedee 442b1a7d81 internal/secret: add a must constructor for the secret client
Multiple packages have a need for a secret client which exits when the
creation of the client failed. This change adds a must constructor
which would eliminate the code being duplicated.

For  golang/go#37171

Change-Id: I7f56ee681e66c42e290fa00861cb00abb56a2f47
Reviewed-on: https://go-review.googlesource.com/c/build/+/255941
Trust: Carlos Amedee <carlos@golang.org>
Trust: Alexander Rakoczy <alex@golang.org>
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-09-22 02:20:15 +00:00
Julie Qiu f1e0897840 cmd/gopherbot: address comments from CL 256179
This CL addresses post-merge comments from CL 256179.

Change-Id: I31f7d9cb521442a28697806380bf26b981d1062e
Reviewed-on: https://go-review.googlesource.com/c/build/+/256337
Trust: Julie Qiu <julie@golang.org>
Run-TryBot: Julie Qiu <julie@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-09-21 15:59:23 +00:00
Julie Qiu 86ff168dcb cmd/gopherbot: label x/pkgsite issues as pkgsite
x/pkgsite issues now use the pkgsite label instead of go.dev. Gopherbot
is updated accordingly.

The Documentation label will not be automatically applied to x/pkgsite
issues.

Change-Id: I9f399c38a72dec74e0b8dc742b762b26a84cd022
Reviewed-on: https://go-review.googlesource.com/c/build/+/256179
Trust: Julie Qiu <julie@golang.org>
Run-TryBot: Julie Qiu <julie@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-09-21 15:34:52 +00:00
Alexander Rakoczy bbb3aae8c4 cmd/gopherbot: skip labeling nonexistent issues
When an issue is transferred, we incorrectly continue trying to manage
the issue with Gopherbot, even though we should be able to pick up the
new issue and decide if it is Gopherbot's responsibility. As a temporary
fix, this change skips issues which return a 404 when adding labels.

For golang/go#40640

Change-Id: Ib84490c1e41a71b14c0f736a41d1f6032a3c2c92
Reviewed-on: https://go-review.googlesource.com/c/build/+/256040
Trust: Alexander Rakoczy <alex@golang.org>
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-09-18 21:36:32 +00:00
Alexander Rakoczy d7661732bd cmd/gopherbot: label x/pkgsite issues as go.dev
The feedback link (https://golang.org/s/discovery-feedback) was updated
to use an issue title prefix of x/pkgsite. We should label issues based
on the new prefix as well.

Fixes golang/go#41481

Change-Id: Id7615b8996c2d945d405a5996136fbb7cece42cf
Reviewed-on: https://go-review.googlesource.com/c/build/+/255939
Trust: Alexander Rakoczy <alex@golang.org>
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-09-18 19:20:34 +00:00
Carlos Amedee 301a72cb1a cmd/rundockerbuildlet: retrieve host type from metadata on EC2
When rundockerbuildlet is running on an EC2 instance, the
configuration should be pulled in from the metadata. This is part of
the effort to move some configuration for builders over to the
coordinator.

For golang/go#36841

Change-Id: Icbf0e73301faadd06c87f02aa1172bd0e6f87624
Reviewed-on: https://go-review.googlesource.com/c/build/+/252317
Run-TryBot: Carlos Amedee <carlos@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2020-09-01 20:43:17 +00:00
Alexander Rakoczy d6a7ee82f7 cmd/relui: load development state on boot
When relui starts, it will look in dev-data-directory for data
persisted from the last boot. This enables local development to continue
when testing changes manually, building on CL 246298.

For golang/go#40279

Change-Id: I02f8b6e1178f82425cafcd2a0544327ba84e028e
Reviewed-on: https://go-review.googlesource.com/c/build/+/250917
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-08-27 19:03:20 +00:00
Dmitri Shuralyov 6464c3e642 cmd/coordinator: warn about known linux-arm SlowBot issue
The current linux-arm builder is known to have trouble when used as
a SlowBot. Start warning about it when the builder is requested via
the TRY= SlowBot UI.

I've considered also removing or disabling the "arm" SlowBot alias,
but that would make it easier to miss that there's an issue, since
SlowBots don't warn about unknown builders:

	If you specify an unknown TRY= token, it'll just ignore it
	and won't report an error.

We can consider making further changes as this situation evolves.
The goal here is to start notifying about a known problem sooner.

For golang/go#35628.
For golang/go#40872.

Change-Id: Ibc1205720c44ec4823c632c04fc2f887368258c1
Reviewed-on: https://go-review.googlesource.com/c/build/+/249420
Reviewed-by: Carlos Amedee <carlos@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-08-20 21:19:38 +00:00
Carlos Amedee 148ff27ab5 cmd/coordinator: enable EC2 buildlet pool
This change enables the EC2 buildlet pools.

Updates golang/go#38337
Fixes golang/go#36841

Change-Id: I3f9384c039dce8fab529650bc6acdbeda40f5819
Reviewed-on: https://go-review.googlesource.com/c/build/+/247908
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-08-18 15:22:56 +00:00
Dmitri Shuralyov 682b3dda28 cmd/updatecontrib: add golang.org/{dl,x/mod,x/pkgsite} repos
These repositories use the Go license and have a minimal CONTRIBUTORS
file that points to the one in the main Go repository, so contributors
to those repositories should be considered by the updatecontrib tool.

For golang/go#12042.
Updates golang/go#36047.

Change-Id: Ia8932f37de0a58a8156f7857806a4d607ca3dd6d
Reviewed-on: https://go-review.googlesource.com/c/build/+/247777
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Julie Qiu <julie@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-08-10 21:50:40 +00:00
Alexander Rakoczy 22f2f0865f cmd/gopherbot: skip commenting on nonexistent issues
When an issue is transferred, we incorrectly continue trying to manage
the issue with Gopherbot, even though we should be able to pick up the
new issue. As a temporary fix, this change skips issues which return a
404 when trying to comment.

For golang/go#40640

Change-Id: I9280fab7a8ec4ead0d3e1cc5695d9b7eb39d6b32
Reviewed-on: https://go-review.googlesource.com/c/build/+/247409
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-08-07 20:47:25 +00:00
Rebecca Stambler 1dcd8460d7 cmd/gopherbot: fix bug causing infinite reviewer assignments
And reenable auto-assignment. This issue was introduced in CL 236438 -
the gerritInstanceID variable already includes the @, so the GetPerson
lookup was failing due to the incorrect formatting.

Fixes golang/go#40468

Change-Id: I5a8d884a7526ee53e04da673c542ed4097c55a2e
Reviewed-on: https://go-review.googlesource.com/c/build/+/247239
Reviewed-by: Andrew Bonventre <andybons@golang.org>
2020-08-06 20:52:36 +00:00
Andrew Bonventre c32acf8915 cmd/gopherbot: temporarily disable assigning reviewers
This is potentially caught in an infinite loop, which updates
a Gerrit change too many times, leaving the change in an unusable
state.

Also adds a map of deleted issues to prevent an error loop caused
by attempting to post changes to issues that don’t exist.

Updates golang/go#40147
Updates golang/go#40468

Change-Id: I3922d63c146591809324861d40437f43e115748c
Reviewed-on: https://go-review.googlesource.com/c/build/+/247195
Run-TryBot: Andrew Bonventre <andybons@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-08-06 20:33:03 +00:00
Alexander Rakoczy 1c75e201d9 cmd/relui: add persistence to development database
This change renames memoryStore to fileStore, and persists data created
in the UI. This will help make local development less painful when
testing changes. Data stored is intended to be loaded at start-up, which
will be implemented in a future change.

For golang/go#40279

Co-authored-by: Carlos Amedee <carlos@golang.org>
Change-Id: Id2390c35b8e1d1d368fbf7ac13b3cdef0776ad87
Reviewed-on: https://go-review.googlesource.com/c/build/+/246298
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Andrew Bonventre <andybons@golang.org>
2020-08-05 18:56:25 +00:00
Dmitri Shuralyov 56b7eeaa78 cmd/release: start using FreeBSD 11.2 builders for Go 1.15 RC 2+
Add the ability to have builds apply only to select Go versions
according to a module-query-like but fictional syntax. We don't
need to support all arbitrary queries right away, so start with
a smaller set of queries, and let this inform future work.

Fixes golang/go#40563.
Updates golang/go#40558.

Change-Id: I8f7afa90bfe1f91190cee34af51c012216bba455
Reviewed-on: https://go-review.googlesource.com/c/build/+/246597
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Andrew Bonventre <andybons@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-08-04 15:58:26 +00:00
Dmitri Shuralyov cb64255c8b cmd/relui: add package comment
Copy the description of relui to a package comment.
Adjust README formatting so the header shows up as expected.

For golang/go#40279.

Change-Id: I74b9ee7ff67c94c885aea5231393928e8b5be647
Reviewed-on: https://go-review.googlesource.com/c/build/+/245645
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-07-30 15:47:19 +00:00
Alexander Rakoczy a6019d6d47 cmd/relui: add proto definition for workflows
Using configuration for our workflows will help separate concerns
between implementation and workflow configuration.

Eventually, similar tasks can be re-used in different workflows, such as
fetching from Git, updating the VERSION file, or publishing a tag.

The current configuration definition is mainly illustrative, and is
expected to change as we build out a prototype.

For golang/go#40279

Change-Id: I5c6f8a18571ab819de0b1d026c86050735efeed9
Reviewed-on: https://go-review.googlesource.com/c/build/+/243340
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Andrew Bonventre <andybons@golang.org>
2020-07-29 21:18:03 +00:00
Alexander Rakoczy 0afb23ebdb cmd/relui: enable creation of mock workflow
This change introduces mock data, multiple templates, and an in-memory
store to the release automation webserver. The goal of this change is to
introduce a basic UI structure. The underlying data infrastructure is
only for mock purposes, and will be replaced in a future CL.

This change enables creation and viewing of an in-memory workflow, with
very minor data stored.

List screenshot:
https://storage.googleapis.com/screen.toothrot.net/pub/2020-07-17-workflow-list.png

New workflow screenshot:
https://storage.googleapis.com/screen.toothrot.net/pub/2020-07-01-11_23_17-workflows-new.png

For golang/go#40279

Change-Id: Id9dfcc01cb2aba1df3e36d7a6301bbf8b47476da
Reviewed-on: https://go-review.googlesource.com/c/build/+/243339
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Andrew Bonventre <andybons@golang.org>
2020-07-29 21:17:44 +00:00
Alexander Rakoczy add5b1118b cmd/relui: add relui webserver for releases
This commit introduces relui, a prototype for running releases in a
persistent server environment. The primary goals of using a long-running
service for release management is to improve observability, scheduling,
and testing of our release process.

This change introduces a very basic webserver, and minimal styling.

For golang/go#40279

Change-Id: I5958e5dc19e62df92b36c64583058cbcef8dd75c
Reviewed-on: https://go-review.googlesource.com/c/build/+/243338
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Andrew Bonventre <andybons@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-07-29 21:17:35 +00:00
Dmitri Shuralyov 7478086087 cmd/releasebot: remove obsolete checkDocs check
The check was added for golang/go#34045, back when doc/contrib.html
lived in the main repo and needed to be manually updated before each
major Go release. This is no longer applicable after CL 229483 and
CL 229485, so remove it before the upcoming Go 1.15 release.

This is compatible with future major releases and does not affect
upcoming minor releases of previous major releases.

Fixes golang/go#40476.
Updates golang/go#34045.

Change-Id: Ifc54dce106633e3d6b9ccdb0db4dae2b7434ce93
Reviewed-on: https://go-review.googlesource.com/c/build/+/245477
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-07-29 15:32:44 +00:00
Carlos Amedee 999f6e20ba buildenv, cmd/debugnewvm: add a region to the AWS configuration
This change adds a region for AWS services to the build environment
configuration. The region for the debug vm tool is set in the
corresponding enviornment chosen by the flags set by
buildenv.RegisterFlags call. The region can be overriden
by setting the awsRegion flag.

The identifier for the security groups has been changed to the name of
the group instead of the id since that is what the AWS API expects.
The AWS availability zones have been added to the staging environment.

Updates golang/go#36841

Change-Id: Iee64257dd68d3a75027aaed13f3e767af48a406c
Reviewed-on: https://go-review.googlesource.com/c/build/+/236797
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-07-17 20:48:01 +00:00
Alexander Rakoczy 6a30d04156 cmd/release: remove oldlink binary from release artifacts
The oldlink tool is used for debugging changes to the linker. While it
was useful to include in the beta, it is less useful in the general
release. Users can still build oldlink themselves for testing.

Tested by running a dry-run release on releasebot.

Fixes #39509

Change-Id: If5d14616b136e9459993cb0e6cfb989da2cf1b96
Reviewed-on: https://go-review.googlesource.com/c/build/+/242643
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-07-14 23:09:12 +00:00
Rebecca Stambler 3e9ba74c2b cmd/gerritbot: don't abandon CLs for branches other than master
Fixes golang/go#40151

Change-Id: I1e5d7f32b2e61bc96ddbb6b5258d26f74c66049f
Reviewed-on: https://go-review.googlesource.com/c/build/+/242157
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Andrew Bonventre <andybons@golang.org>
2020-07-13 18:43:11 +00:00
Rebecca Stambler cd7372b931 cmd/gopherbot: fix missing import
I must have not rebased CL 241271 before submitting, because somehow,
there's a missing import.

Change-Id: Id050fb547258a2733935f90f35260a60a3815fb2
Reviewed-on: https://go-review.googlesource.com/c/build/+/241858
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-07-10 03:10:07 +00:00
Rebecca Stambler 2aa5be62af cmd/gopherbot: remove automatic troubleshooting comment
I think the usefulness of this has run its course. There's very little
evidence that anyone is ever actually reading the troubleshooting guide.

Change-Id: I903e39c870bbafa377c72ae40b1b0bbffccfb37e
Reviewed-on: https://go-review.googlesource.com/c/build/+/241271
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Heschi Kreinick <heschi@google.com>
2020-07-08 05:19:48 +00:00
Rebecca Stambler cfe9ff1979 cmd/gopherbot: don't set reviewers if they are the same as current
This change avoids calling SetReview with reviews that would have no
effect on the change. This is particularly relevant for changes imported
from PRs, as they require 2 reviewers. If there is only one owner for
the package, we should avoid continually setting the same reviewer.

This change is implemented by keeping track of all of the human
reviewers on a given change and comparing them to the proposed
reviewers. This is a little complicated, given that the current
reviewers can only be kept track of by their Gerrit IDs, whereas owners
are added by the emails associated with their Gerrit accounts.

Change-Id: I684c8c86fd5c0c2c411450ae48a332ba796f5d60
Reviewed-on: https://go-review.googlesource.com/c/build/+/236438
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Andrew Bonventre <andybons@golang.org>
2020-07-07 16:49:07 +00:00
Keith Randall c8669bad33 cmd/gomote: list current instances on emtpy gomote destroy command
Just a usability tweak. After typing "gomote destroy" and realizing
I don't have the instance name handy, it's easier to just hit
return instead of backspacing over "destroy" and typing "list" instead.

Change-Id: I8d05c9c9925b08ad1f58cf1eaeffa66db34a773c
Reviewed-on: https://go-review.googlesource.com/c/build/+/239757
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2020-06-24 16:00:30 +00:00
Dmitri Shuralyov b706b59ae3 cmd/releasebot: document that all release types are supported
Releasebot has achieved the milestone of supporting all release
types some time ago. Let it have this badge of honor, so it can
celebrate and show off to its robot friends.

Also adjust the phrasing in nextStepsPrepare and nextStepsBeta
to be more clear when only the prepare stage has completed.

For golang/go#34045.

Change-Id: Ie4771ab6b6692a26c3363a3a35f131edd2d569cf
Reviewed-on: https://go-review.googlesource.com/c/build/+/239038
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-06-23 15:29:38 +00:00
Dmitri Shuralyov 3228d3c70d cmd/releasebot: opt into using windows-amd64-longtest target by default
The windows-amd64-longtest target is passing on master (for Go 1.15),
release-branch.go1.14, and release-branch.go1.13. It was successfully
opted-into during the Go 1.15 Beta 1 release (see golang/go#39502).

Start including it in the release process by default, so that we have
more information available during the upcoming releases, and in turn
can use it to improve the releases and the release process further.

Also improve the formatting of the release table to improve
its readability, based on experience from golang/go#39502.

For golang/go#29252.

Change-Id: I002c3bf811facf50ca5fb363adebe2baacd039ea
Reviewed-on: https://go-review.googlesource.com/c/build/+/238539
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-06-18 23:55:29 +00:00
Carlos Amedee 07bebbe343 cmd/debugnewvm: add EC2 buildlets
This adds the ability to debug the creation of buildlets which run
on EC2.

Updates golang/go#36841

Change-Id: Ib6891bc6ea985716f76e5668ade178541073a344
Reviewed-on: https://go-review.googlesource.com/c/build/+/236577
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-06-16 16:22:19 +00:00
Carlos Amedee 87d102082c buildlet: use cloud client with AWS buildlet
Use the cloud package for AWS functions. Remove the unused
destroyVM function.

Updates golang/go#36841

Change-Id: I00e1a20c904f7c4be6460ac302085b28f518d161
Reviewed-on: https://go-review.googlesource.com/c/build/+/236300
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-06-16 13:47:54 +00:00
Dmitri Shuralyov 6b5029f2f0 cmd/releasebot: remove okay-after-beta1 label after beta1 is released
The okay-after-beta1 label is used to mark that a given issue with
the release-blocker label for a given major release milestone is
okay to resolve after beta1. When the beta1 is released for that
milestone, by definition, all remaining issues with release-blocker
label must be okay to resolve after beta1 and will have the label
indicating that.

That means the okay-after-beta1 label loses its meaning after beta1
is released. Since it takes up visual space, automatically remove it
from all release-blocker issues in the same milestone, and open up
more room for a potential future "okay-after-rc1" label or so.

Modify pushIssues to match the release status issue by issue
number rather than by title (keeping golang/go#39371 in mind).
Also modify pushIssues and check{,Beta1}ReleaseBlockers to match
milestones by ID rather than by name. This is to be more robust.

Change-Id: If74654375253185cc5e6488d344ec7b2b5195011
Reviewed-on: https://go-review.googlesource.com/c/build/+/236260
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-06-03 14:19:37 +00:00
Dmitri Shuralyov 48f1cdd52e cmd/releasebot: trim pre-release suffix in getMilestone
Pre-release versions like go1.15beta1 use the same milestone
as the release version go1.15, a milestone named "Go1.15".
Handle this in getMilestone by trimming the pre-release suffix.

Also simplify ForeachMilestone error handling. The only error
ForeachMilestone returns is that of fn, which isn't interesting.

For golang/go#39345.

Change-Id: I19ddca7736d97791cc6d7d6986fd39c61db437e2
Reviewed-on: https://go-review.googlesource.com/c/build/+/236259
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-06-03 14:16:21 +00:00
Dmitri Shuralyov e566a70d10 cmd/releasebot, cmd/release: include long tests in release process
The goal of this change is to reduce the chance of issuing a release
with an unintended regression that would be caught by running long
tests. This change adds long tests that are run during the -prepare
step, in addition to all the existing short tests that are run.

Executing the long tests is implemented by adding two new test-only
release targets. For a release to be considered complete, all release
targets must complete.

These test-only targets are built only for the purpose of verifying
their tests succeed, or to block the release otherwise.
They do not produce release artifacts.

The new test-only targets are named after the builder which is used
to perform their tests, and they are:

• linux-amd64-longtest
• windows-amd64-longtest

More builders may be added in the future, but care must be taken
to ensure the test execution environment is as close as possible
to that of build.golang.org post-submit builders, in order to
avoid false positives and false negatives.

As part of a gradual rollout, this change also adds a flag to skip
longtest builders. It's meant to be used in case a long test proves
to be flaky, and enough confidence can be gained through testing
elsewhere that the failure is not a regression caused by a change
merged to the release branch.

For now, its default value includes both longtest builders, so they
are currently opt-in and this CL is a no-op. After testing proves
that it is viable to rely on this (and any issues preventing that
from being possible are resolved), the default value of the flag
will be changed to the empty string.

For golang/go#29252.
For golang/go#39054.
For golang/go#37827.
Fixes golang/go#24614.

Change-Id: I33ea6601aade2873f857c63f00a0c11821f35a95
Reviewed-on: https://go-review.googlesource.com/c/build/+/234531
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-06-02 19:50:27 +00:00
Dmitri Shuralyov e0af7f00b9 cmd/releasebot: add check for beta1 release blockers
We now have a way of telling which release blocker issues apply to
a beta1 release, so start checking for such issues, and prevent
the release from proceeding if any of them are open.

Fixes golang/go#39345.

Change-Id: Id77098c9e72f45e043f97fa2b22bac811f29b0a4
Reviewed-on: https://go-review.googlesource.com/c/build/+/235778
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-06-02 19:37:05 +00:00
Dmitri Shuralyov 1d2bb0dc3f cmd/releasebot: factor out version checks from doRelease
Previously, the GitHub milestones were searched for first,
and version validation was done second. This refactor moves
the error checks to happen earlier, in main. That gives
confidence the version has passed checks before starting
to look for a milestone.

Improve documentation of the Milestone and NextMilestone fields,
and always populate the current Milestone field for all releases.

This helps the upcoming change in CL 235778, where a check for
release blocker issues is being added for beta1 releases.

For golang/go#39345.

Change-Id: Id1cda24a0e140e1e2d02e47b78f353157d4c743a
Reviewed-on: https://go-review.googlesource.com/c/build/+/235937
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-06-02 19:36:14 +00:00
Rebecca Stambler 147530976d cmd/gopherbot: restructure congratulatory messages for x/repos
This change splits out the paragraph mentioning the freeze from the
default congratulatory message, only showing it if the CL is to a
golang/go repository.

Running gopherbot with --dry-run reports no changes, which is expected
since all CLs that should get congratulatory messages probably already
have them.

Fixes golang/go#39160

Change-Id: I4d0f6c25a9403033c87bf8884a2224927629192d
Reviewed-on: https://go-review.googlesource.com/c/build/+/234897
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Andrew Bonventre <andybons@golang.org>
2020-06-01 23:16:59 +00:00
Dmitri Shuralyov 83d1cf6c88 cmd/releasebot: use same master commit for beta releases
The prepare mode is responsible for doing testing to ensure
all tests are passing. If a problem is found, it can be fixed
and the prepare mode should be re-done.

The release mode is responsible for taking the well-tested
commit from the prepare mode, and using it to build the release.

For beta releases, the master branch is used, and a commit has a
chance of landing between the time the prepare and release modes
are started.

Instead of fetching the latest master commit in release mode,
start reusing the same master commit that was already tested
in prepare mode.

Fixes golang/go#36182.
For golang/go#36171.

Change-Id: Ibf8052ef385cb0a1ffed372ae3e0ed0a9575882f
Reviewed-on: https://go-review.googlesource.com/c/build/+/235777
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2020-06-01 15:26:46 +00:00
Rebecca Stambler bdb4c1fd7a cmd/gopherbot: fix reviewer assignment for CLs imported from PRs
golang/go#30265 causes Gerrit to add the authors of PRs as reviewers on
the imported CLs. Then, when Gopherbot assigns reviewers to the PR, it
seems a human reviewer already listed, meaning that a lot of CLs never
get assigned reviewers and are then never replied to.

As a work-around for these issues, require two reviewers on all PRs.

Fixes golang/go#31658

Change-Id: I7b3f62194450cba61493d8c4c0ad14320443e641
Reviewed-on: https://go-review.googlesource.com/c/build/+/227977
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Andrew Bonventre <andybons@golang.org>
2020-05-28 15:16:39 +00:00
Rebecca Stambler 0a9a8b56c7 cmd/gerritbot: abandon CLs imported from PRs that have been closed
When the code checks if the PR has been closed, we should also abandon
its corresponding CL, so add this behavior.

Also, while I'm here, I fixed a few staticcheck issues that gopls
noticed :)

Fixes golang/go#23850

Change-Id: Ifd7700612802edb68a232f08436109e71e31fb41
Reviewed-on: https://go-review.googlesource.com/c/build/+/234179
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-05-26 16:07:25 +00:00
Dmitri Shuralyov 4872bffdee cmd/gerritbot: use secret manager only when run in GCE
Restore the ability to test gerritbot locally in dry-run mode.

Update some references to compute metadata with secret manager,
since that is what's used now.

Also add a safety check at the top of postGitHubMessageNoDup.
This increases confidence that it is safe to use dry-run mode,
and may help in case it's ever called in non-dry-run mode.

For golang/go#37171.
For golang/go#23850.

Change-Id: I6d7ea228294fc07b6167317ddcf066507e0c0d08
Reviewed-on: https://go-review.googlesource.com/c/build/+/234889
Reviewed-by: Carlos Amedee <carlos@golang.org>
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2020-05-21 23:34:09 +00:00
Rob Findley 00a957a3ed cmd/fetchlogs: fetch repo data using the 'repo' query param
The repo flag for fetchlogs is not currently that useful because it
queries the main Go dashboard data, which only has a few commits for
each subrepo. This was probably because the data at
  https://build.golang.org/?repo=<import path>&mode=json
was incorrect due to golang/go#35515.

With golang.org/cl/232897, this data should be corrected. Update
fetchlogs to now query data from the subrepo dashboard.

Change-Id: I352662abf7da6abb7bc23888b11e03927f567cab
Reviewed-on: https://go-review.googlesource.com/c/build/+/232898
Run-TryBot: Robert Findley <rfindley@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2020-05-18 19:47:01 +00:00
Carlos Amedee 92f0c56520 cmd/rundockerbuildlet, buildlet: enable running arm EC2 instances
This enables rundockerbuildlet to run non-reverse buildlet
image on EC2. It will only run a single instance of rundockerbuildlet
once. It exposes port 443 for the coordinator to authenticate with the running
buildlet.

This also adds the buildlet name and buildlet container URL to
the EC2 user data struct retrieved by rundockerbuildlet.

Updates golang/go#36841

Change-Id: I31de754e2ac8970c6f18993104de0e0baea5dc31
Reviewed-on: https://go-review.googlesource.com/c/build/+/234114
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-05-15 22:01:25 +00:00
Dmitri Shuralyov 511221c1b1 cmd/gopherbot: print referenced repo in closeCherryPickIssues
Calls to addGitHubComment and closeGitHubIssue operate on ref.Repo.ID(),
so use it in printIssue call too, rather than hard-coding b.gorepo.ID().

There's no change in behavior now because the closeCherryPickIssues task
only closes issues in the main Go repository at this time, but it should
prevent confusion if that changes in the future.

For golang/go#39008.

Change-Id: Idb72eb884a917ce1eb4d9cc7fb6114e52ddee9db
Reviewed-on: https://go-review.googlesource.com/c/build/+/234023
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
2020-05-15 16:25:53 +00:00
Rebecca Stambler cf70d9152a cmd/gopherbot: extend gopherbot's general tasks to the vscode-go repo
GopherBot has a few tasks, such as automatically applying labels and
closing stale issues, which are applicable to all golang.org/x repos,
not just golang/go. This change makes these work for golang/go and
golang/vscode-go, with the eventual intention of making them work for
more repos.

Updates golang/go#39008

Change-Id: I4aad54822422747aeac25590de3069562bebb3a5
Reviewed-on: https://go-review.googlesource.com/c/build/+/233377
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-05-15 02:54:19 +00:00
Carlos Amedee 6d6d183c6f cmd/buildlet: retrieve metadata on EC2 instances
User defined metadata on EC2 instances are stored in
the user data section of the metadata. This CL enables
the retrieval of that metadata and retrieval of that
data via already defined keys.

Updates golang/go#36841

Change-Id: I485b36676ca636bbf2caef9af3fd7174f93dff5e
Reviewed-on: https://go-review.googlesource.com/c/build/+/233800
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-05-14 02:42:48 +00:00
Carlos Amedee 690003452d cmd/buildlet/stage0: add arm aws hosts
This enables stage0 to be used on linux arm
and arm64 AWS instances.

Updates golang/go#36841

Change-Id: I597b8001ab00e701f6547748235d8967f5f5936c
Reviewed-on: https://go-review.googlesource.com/c/build/+/233799
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2020-05-13 20:45:56 +00:00
Carlos Amedee d954505435 cmd/genbuilderkey: add usage information
This change adds usage information to the genbuilderkey command.
This defines what the requirements and arguments are for executing
the command.

Change-Id: Ie6c465f682c4f78a34a30db09a0e710dd071b4b8
Reviewed-on: https://go-review.googlesource.com/c/build/+/232217
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-05-05 19:03:33 +00:00
Carlos Amedee 642a88e7df env/linux-arm64/aws: add linux-arm64-aws builder image
This adds the ability for linux-arm64 builder images to be
created on AWS. Instead of writing a bash script which would create
an image with all of the dependencies on it, this experiments with
using packer to create the image.

The image is configured to install and daemonize rundockerbuildlet.
Rundockerbuildlet will download and run the latest stage0 image.
Stage0 then downloads the latest buildlet and begins processing jobs.

A follow-up change will enable rundockerbuildlet to initialize the
buildlet without setting it in reverse mode.

Updates golang/go#36841

Change-Id: Iee07c2600e2b91d34f5e6a1e062f763833d79904
Reviewed-on: https://go-review.googlesource.com/c/build/+/228799
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-05-04 21:27:33 +00:00
Carlos Amedee 3e01d876bf dashboard: remove the Windows ARM builder
The host-windows-arm-iotcore builder has been missing for an
extended period of time. Attempts to contact the maintainer have
failed. This removes the builder until we can find a replacement
for windows-arm instances.

Fixes golang/go#38493
For golang/go#38607

Change-Id: Ia7d2168f676a86bced754688b4e2d52e61f3125b
Reviewed-on: https://go-review.googlesource.com/c/build/+/229559
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-04-23 15:40:42 +00:00
Carlos Amedee 7858236789 internal/pool: remove package level accessors
This change moves all package level accessors into a struct as
suggested by Alex:
https://go-review.googlesource.com/c/build/+/227141/6/internal/coordinator/pool/gce.go#227
This will make it easier to move away from global state in
future changes.

Updates golang/go#36841
Updates golang/go#38337

Change-Id: I005884ccd206fe49651d31ef1d3d336fac9c3d5f
Reviewed-on: https://go-review.googlesource.com/c/build/+/227920
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-04-20 15:46:52 +00:00
Carlos Amedee 26e1579cd0 internal/pool: move the reverse buildlet pool into a pool package
This is a set in a series of steps which will move everything buildlet
pool related into a pool package.

Updates golang/go#36841
Updates golang/go#38337

Change-Id: Ic7a0ccd7838345036df2e72b13084070541cb63c
Reviewed-on: https://go-review.googlesource.com/c/build/+/227769
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-04-20 15:26:44 +00:00
Carlos Amedee 1f68cb08aa internal/pool: move the kubernetes buildlet pool into a pool package
This is a set in a series of steps which will move everything buildlet
pool related into a pool package.

Updates golang/go#36841

Change-Id: I8efb1f94c7b929be559004d9f455bca0370c7800
Reviewed-on: https://go-review.googlesource.com/c/build/+/227768
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-04-20 14:43:08 +00:00
Carlos Amedee 02e10adc88 internal/pool: move the gce buildlet pool into a pool package
This CL creates the internal/coordinator/pool package intended to
contain all buildlet pool implementations. In order to keep this
change small and carefully discover where the interactions are
between the gce buildlet pool and the rest of the coordinator
are, this change only moves the gce buildlet over to the new
package.

The next steps will be to move the rest of the buildlet pools
over to this package. After that we will restructure the
implementations themselves in order to increase test coverage
and increase the ease of testing.

Updates golang/go#36841
Updates golang/go#38337

Change-Id: If82ae1b584bd77c697aa84fadf9011c9e79fa409
Reviewed-on: https://go-review.googlesource.com/c/build/+/227141
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-04-20 14:42:36 +00:00
Dmitri Shuralyov f87aadf4bc cmd/gitmirror: update build image to Go 1.14
The timeout added in CL 35124 doesn't seem to be working as intended.
Update to a supported version of Go before investigating further.

Also remove the explicit GOPROXY override, since the default behavior
as of Go 1.13 uses the Go module mirror¹.

¹ https://golang.org/doc/go1.13#introduction

For golang/go#35124.

Change-Id: Ia01abc530f0284791fe6e57ce5700c0ebc75268e
Reviewed-on: https://go-review.googlesource.com/c/build/+/227858
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-04-10 15:31:53 +00:00
Dmitri Shuralyov 81f06ce67b cmd/coordinator, dashboard: don't skip cmd/dist tests for SlowBots
When a user explicitly requests a SlowBot builder via the TRY= syntax,
it is a signal that they're willing to wait longer for test results.
It's more useful to not skip any tests and give the user confidence
that the SlowBot run will catch all issues that would otherwise be
caught only by post-submit builders after the CL is submitted.

This is done by considering a TryBot that isn't an explicit SlowBot
to be a "normal TryBot", and the ShouldRunDistTest policy function
is provided a parameter specifying whether it's a normal TryBot
(non-SlowBot) run.

Tests are only skipped during normal TryBot runs, not SlowBot runs.

Fixes golang/go#38279.
For golang/go#34501.

Change-Id: Ia11fd51c71f9de1089b6b6f4c027014893f224b9
Reviewed-on: https://go-review.googlesource.com/c/build/+/227779
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-04-09 23:13:34 +00:00
Dmitri Shuralyov 2dd4548ea0 cmd/coordinator: consider explicitly requested builders as SlowBots
Previously, a builder was considered to be "SlowBot" whenever it was
requested via the TRY= syntax, and it wasn't already a part of the
default set of trybot builders.

This change makes it so that a builder is considered a SlowBot if
it was explicitly requested via the TRY= syntax, even if it was
already going to run anyway.

The goal behind this change is to improve the experience of using
SlowBots, by making them more useful and predictable.

The UI currently reports that "SlowBots are starting ..." whenever
there is a non-zero amount of SlowBots. So if a user requested
TRY=linux-amd64, they'd likely see "TryBots are starting ...",
which can be misunderstood to mean that SlowBots are not working.

Additionally, if a user requested three builders via TRY= syntax,
but one of them happened to be a part of the default try set, then
the message at the end would be "Extra slowbot builds that ran:"
including only 2 builders. At that point, it's hard to tell whether
they got the TRY= syntax wrong for one of the builders, or if it was
omitted because it's always run anyway.

A future usability improvement in golang.org/issue/38279 is to make
SlowBots not skip any tests that normal trybots may skip for faster
results. This change is in preparation for that.

For golang/go#38279.
For golang/go#34501.

Change-Id: Idb7f1bcb1694fe72f85237976995a94f273c7c16
Reviewed-on: https://go-review.googlesource.com/c/build/+/227778
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-04-09 23:01:01 +00:00
Keith Randall 6825d11d73 cmd/racebuild: use 9.0 netbsd builders
They have the increased disk space this script needs to work.

Change-Id: I782fc121db0326c5dc1c267d08fd7320f38c65b6
Reviewed-on: https://go-review.googlesource.com/c/build/+/227546
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-04-09 18:07:33 +00:00
Keith Randall 8d25bb5d93 cmd/racebuild: fix windows chocolatey download
Updated with the latest chocolatey install instructions.
An additional incantation is required to establish a SSL connection.

Change-Id: I6786d66f57dbb68260055d38be4f64d8e393a404
Reviewed-on: https://go-review.googlesource.com/c/build/+/226879
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2020-04-09 18:07:22 +00:00
Rebecca Stambler fdec4c9164 cmd/coordinator: support running TryBots on x/ repo branches
This change fixes a bug that was preventing TryBots from running on
branches of the x/ repositories, other than "master" and
"release-branch.go1.N". For now, we only run TryBots with Go at tip.

Fixes golang/go#37512

Change-Id: I99f11f570252d5612ef11ecaa3335c4478cda730
Reviewed-on: https://go-review.googlesource.com/c/build/+/227397
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-04-08 21:07:59 +00:00
Dmitri Shuralyov 39561bf345 cmd/coordinator: add test for trybot release-branch.go1.N branch matching
Issue golang.org/issue/28891 was that golang.org/x repo trybots were
always using Go tip, even when testing release-branch.go1.N branches.
It should instead be using Go version 1.N in those situations.

This was fixed in CL 167382. However, that change also caused there
to not be any builder coverage for golang.org/x repo branches other
than "master" and "release-branch.go1.N" ones.

There was no test coverage for that behavior, and we didn't really
have any other branches, so no one noticed. By now, there are some
golang.org/x repos that have other branches, so this was reported
in issue golang.org/issue/37512. Fixing that issue is made harder
because we don't have a regression test for issue 28891 yet.

To make it easier to fix both of these overlapping issues without
having one undo the other, start by adding a test for issue 28891.
CL 227397 fixes issue 37512 and adds a test for it, so hopefully
neither will regress from now on.

For golang/go#28891.
For golang/go#37512.

Change-Id: I3475820a840a25532fb7e722c18b3d0dee3e0734
Reviewed-on: https://go-review.googlesource.com/c/build/+/227537
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
2020-04-08 15:14:30 +00:00
Carlos Amedee 0cae7ddc56 cmd/coordinator/spanlog: remove spanlog package
This removes the spanlog package located inside the
coordinator package. The spanlog package has already been
copied over to the internal package. All imports in the build
repository have been changes to point to the internal spanlog
package.

Updates golang/go#36841

Change-Id: I84499bcfe782c566b12dabcbfa743cd8ce559f18
Reviewed-on: https://go-review.googlesource.com/c/build/+/227023
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-04-07 16:10:23 +00:00
Dmitri Shuralyov 2c61532811 cmd/coordinator: report errors on all gitmirror instances
There are 2 gitmirror instances running since 2017 (CL 36801).
The gitmirror health check has been relying on fetching the HTML
status page from the gitmirror service via its load balancer.

If one of of the two gitmirror instances has a problem, the health
check can miss it and report all okay. This caused the health check
to appear flaky and untrustworthy, even though the underlying failure
in gitmirror is reported reliably.

Start querying all gitmirror instances and report combined errors.
Also report a problem if there are no gitmirror instances running.

Remove the /debug/watcher/ debug endpoint. Its current implementation
is unhelpful because the load balancer causes it to display the status
of a single instance. Making it useful would require significant rework.
In the meantime, the status pages of individual gitmirror instances can
be accessed by using the kubectl port-forward command.

Fixes golang/go#37828.

Change-Id: I3f3e322a85e07f23f18a56a7fd913abed75ee77e
Reviewed-on: https://go-review.googlesource.com/c/build/+/226678
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-04-01 04:17:40 +00:00
Keith Randall 914a9f1ff8 cmd/racebuild: update build instructions
Update llvm's location - it has moved to github.
Turn status messages from "gomote create" off.

Change-Id: I372b43ab4aff23d6657deeb35f3b40a222ca1e73
Reviewed-on: https://go-review.googlesource.com/c/build/+/226541
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2020-03-31 18:36:37 +00:00
Dmitri Shuralyov 2bf41cd70a dashboard, cmd/buildlet: re-add riscv64 buildlet and misc-compile trybot
This is a re-send of CL 216765, which was reverted in CL 217723
due to the misc-compile-other trybot being broken on linux/riscv64.

By now, the problem that was caught by the misc-compile-other trybot
has been fixed in CL 217777, so we can try again.

Fixes golang/go#36871
Fixes golang/go#37022

Change-Id: Id9e7d7f3e610b17a2d37a2216ab5d3eed139ee1e
Reviewed-on: https://go-review.googlesource.com/c/build/+/224580
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-03-23 18:29:18 +00:00
Carlos Amedee 1e42a94bc4 cmd/coordinator: migrate secrets to secret manager
This change retrieves the coordinator secret keys from secret manager. It
is part of the project to store all secrets in a single location.

Updates golang/go#37171

Change-Id: I91243fbb30a206a66b7645dfd96321d39a835bcb
Reviewed-on: https://go-review.googlesource.com/c/build/+/223197
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-03-13 14:41:05 +00:00
Carlos Amedee 55c9b38919 cmd/genbuilderkey: migrate secrets to secret manager
This change retrieves the master builder key from secret manager. It
is part of the project to store all secrets in a single location.

Updates golang/go#37171

Change-Id: I0c8b8fe8a3db5b9583008bfc105391eca69fba78
Reviewed-on: https://go-review.googlesource.com/c/build/+/222958
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-03-11 16:29:08 +00:00
Carlos Amedee ce16379921 cmd/gitmirror: migrate secrets to secret manager
This change retrieves the GitHub ssh key from secret manager. It
is part of the project to store all secrets in a sigle location.

Updates golang/go#37171

Change-Id: I2cf604975b6ac9998ee39370a1f0f794388a1a70
Reviewed-on: https://go-review.googlesource.com/c/build/+/219879
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-03-10 20:35:40 +00:00
Carlos Amedee 482e5fcc95 cmd/pubsubhelper: migrate secrets to secret manager
This change retrieves the secrets used by pubsubhelper from secret
manager. It is part of the project to store all secrets in a single
location.

The change required updating the ca-certificates in the container. I
made the docker configuration match the gopherbot configuration in
an effort to maintain uniformity.

Updates golang/go#37171

Change-Id: I0d48beccb08ac2e850a99cff1b45df3907b13474
Reviewed-on: https://go-review.googlesource.com/c/build/+/222177
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-03-10 20:25:07 +00:00
Carlos Amedee d18ebdf224 cmd/gerritbot: migrate secrets to secret manager
This change retrieves the secrets used by gerritbot from secret
manager. It is part of the project to store all secrets in a single
location.

Updates golang/go#37171

Change-Id: I34e478b1de83f31028a260516780bf1dad7b33f2
Reviewed-on: https://go-review.googlesource.com/c/build/+/222066
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-03-10 19:19:45 +00:00
Carlos Amedee 65b4327a78 cmd/gopherbot: migrate secrets to secret manager
This change retrieves the secrets used by gopherbot from secret
manager. It is part of the project to store all secrets in a single
location.

Updates golang/go#37171

Change-Id: Id40d0745f00e9c44f2d71b1ba64885e4db6e5ef7
Reviewed-on: https://go-review.googlesource.com/c/build/+/219939
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-03-10 16:50:23 +00:00
Alexander Rakoczy e0eb01c7ec cmd/coordinator/internal/dashboard: filter ErrNoSuchEntity
The AppEngine dashboard filters out datastore.ErrNoSuchEntity, which
happens when we fetch a commit that has no build information yet. This
change ports that functionality to the coordinator dashboard.

Updates golang/go#34744

Change-Id: I38f6b2e1a1805fb24b9e387a5737ff8c2057b625
Reviewed-on: https://go-review.googlesource.com/c/build/+/222197
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-03-09 17:00:35 +00:00
Dmitri Shuralyov 6719201e09 cmd/gerritbot: allow dash in gerritChangeRE
Gerrit repositories may have a dash in their name. Some already do,
such as sublime-build, vscode-go, and so on. Update the regexp to
match git output from Gerrit when a CL is created for those repos.

Add a test to catch future repository names that don't get matched.

Fixes golang/go#37725

Change-Id: I4e64f49148aa2a23ed0e878be6cc11ba9af77877
Reviewed-on: https://go-review.googlesource.com/c/build/+/222437
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-03-09 16:50:47 +00:00
Carlos Amedee 3c1062b30f dashboard: remove OS X 10.10 builders
OS X 10.10 is no longer supported by the latest versions
of Go (1.13 and 1.14). It is no longer in use.

Fixes golang/go#37713

Change-Id: Ibc4a527c17f2dafd00ee0fba2e312394e1ceac9c
Reviewed-on: https://go-review.googlesource.com/c/build/+/222337
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-03-09 16:02:35 +00:00
Alexander Rakoczy 236dbea5aa cmd/coordinator: render partial build dashboard
This change adds a build dashboard handler to the Coordinator. As part
of the effort to remove the app/appengine build dashboard, this moves a
large part of the template and logic into cmd/coordinator.

As part of this change, cmd/coordinator/internal/dashboard has been
created. I originally developed this in the main package, but the main
package is very crowded in the coordinator. Giving the dashboard its own
package also made testing easier.

Currently, this implementation only supports rendering part of the build
dashboard for the Go repository on master. It does not yet link to test
logs, and only shows successful state.

Updates golang/go#34744

Change-Id: I6ffe064b9fc5e4a3271eadfd5ac45d5baf4ebd37
Reviewed-on: https://go-review.googlesource.com/c/build/+/221920
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-03-05 17:35:51 +00:00
Carlos Amedee 7ece5dab5e cmd/release: set the minimum macOS version supported by Go 1.13
Set the minmacos version depending on the version of go being packaged
for macOS releases. Removed support for Go 1.12 since it is no longer
supported.

Fixes golang/go#36846
Updates golang/go#35459

Change-Id: Ifb9a0296fde5ed87da72d7719a714744484cc7db
Reviewed-on: https://go-review.googlesource.com/c/build/+/221100
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-02-26 19:36:12 +00:00
Dmitri Shuralyov 5b56222190 cmd/releasebot, cmd/release: delete code for Go 1.12 and older
Go 1.14 has been released, so there will not be more Go 1.12.x releases
per the release policy¹. Remove various special code paths that applied
only to Go 1.12.x and older releases.

This change should be a no-op for Go 1.13 and newer releases.

¹ https://golang.org/doc/devel/release.html#policy

Change-Id: I94a7666364420ef077d528c351c2cb54e5379b5c
Reviewed-on: https://go-review.googlesource.com/c/build/+/221097
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-02-26 16:15:07 +00:00
Alexander Rakoczy b077d0cce9 cmd/coordinator,cmd/retrybuilds: add wipe API to coordinator
As part of our migration to combine codebases of the Build Dashboard and
the Coordinator, the first step is to start calling a Coordinator API
for wiping release status of failed builds. This adds a gRPC API to the
coordinator, listening on the same port as the HTTPS listeners.

The Coordinator API in this implementation simply validates and forwards
a request to the dashboard API.

This change also updates cmd/retrybuilds to optionally use the
Coordinator gRPC API for wiping.

Tested locally using the live Dashboard API.

Updates golang/go#34744

Change-Id: I4b34b064625193eb11a280565d701605064a8443
Reviewed-on: https://go-review.googlesource.com/c/build/+/219120
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2020-02-20 15:37:57 +00:00
Carlos Amedee de8b20fb66 internal/secret: add secret management package
This change adds a package which can be used to retrieve secrets from
GCP Secret Management Service. The goal of this package is to ensure
that there is a simple and known way to retrieve secrets for any
service housed in the build repository. This package should enable the
storage of the project secrets in a single, secure location.

A simple use of the package is introduced to the scaleway application.

Updates golang/go#37171

Change-Id: I957afc2a8b8cede2c2eaa132513fad3fb3691867
Reviewed-on: https://go-review.googlesource.com/c/build/+/217340
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-02-13 17:21:54 +00:00
Alexander Rakoczy 87c4823281 cmd/gopherbot: add unreleased milestone to go.dev issues
This change updates gopherbot to add the Unreleased milestone for go.dev
issues if they do not yet have a milestone.

Tested locally with dry-run.

Updates golang/go#36749

Change-Id: I1fe0739d15961669950b8f65a8767a09c619943d
Reviewed-on: https://go-review.googlesource.com/c/build/+/217957
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-02-06 15:39:19 +00:00
Alexander Rakoczy 22bdacadd1 cmd/coordinator,buildlet: keep active GCE SSH sessions alive
This CL skips deleting active remote buildlets.

The coordinator has multiple ways of tracking stale buildlets. For our
GCE buildlets, we periodically delete old VMs after their expiration
time, typically 45 minutes after their creation. The expiration tracking
in coordinator/gce.go does not account for remote buildlets, which are
buildlets created by users or cmd/release. Remote buildlets have their
own staleness checks and cleanup process, so we should skip the GCE
specific cleanup logic for them.

This adds an additional field to the buildlet Client in order to
correlate a GCE VM with a buildlet.

Updates golang/go#37001

Change-Id: Ib0acdf79c4dfbee6e0061c513f98b749d4b9cc64
Reviewed-on: https://go-review.googlesource.com/c/build/+/217722
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-02-06 15:35:01 +00:00
Alexander Rakoczy 6c6082de2d Revert "cmd/buildlet: add riscv64 buildlet"
This reverts CL 216765 (git 992a31230c)

Reason for revert: This trybot is broken.

Updates golang/go#37022

Change-Id: I8ff1e53e3edba7c461d1f46701df02b844b1f3a1
Reviewed-on: https://go-review.googlesource.com/c/build/+/217723
Run-TryBot: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2020-02-04 20:09:34 +00:00
Carlos Amedee 5bb938ef02 cmd/release: set the minimum macOS version supported by releases
When the macOS releases were moved over to the macOS 10.15 (Catalina)
builders, the macOS SDK version was set in the resulting
binaries Mach-O commands. When a cgo application was built using
a macOS version earlier than the macOS version (and macOS SDK version)
that Go was built on, the external linker would log warnings about the
version mismatch. Setting the version to the earliest version of macOS
supported by the release eliminates the external linker warnings.

Fixes golang/go#36900
Updates golang/go#36025
Updates golang/go#35459

Change-Id: Ie2ef7216af1ddd2afaffea53eca064bfe5c52d63
Reviewed-on: https://go-review.googlesource.com/c/build/+/216304
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2020-01-31 15:36:28 +00:00
Brad Fitzpatrick 992a31230c cmd/buildlet: add riscv64 buildlet
Somebody else will need to run "make buildlet.linux-riscv64" for me to upload
the binary to GCS.

Updates golang/go#27532
Fixes golang/go#36871

Change-Id: I0ae8dea0f33c79801670d1f9a02a29b31d739e31
Reviewed-on: https://go-review.googlesource.com/c/build/+/216765
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-01-29 19:35:47 +00:00
Dmitri Shuralyov f0a685979f cmd/upload: use specified go version for building
There's an optional -go flag to specify Go version for compilation.
Use it in both invocations of the "go" command, not just the first.

This is a followup to CL 207420 where the -go flag was added.

Change-Id: Ic33b9acf194fb8fda582d3495e4247fec36218e0
Reviewed-on: https://go-review.googlesource.com/c/build/+/216837
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2020-01-29 19:24:36 +00:00
Alexander Rakoczy 933f81f5b4 cmd/gopherbot: label go.dev issues
go.dev and pkg.go.dev now use the Go issue tracker. This will save us a
little bit of effort triaging.

Fixes golang/go#36749

Change-Id: I2840178afdb4b358f424c28c3e36a6cf5de50dd9
Reviewed-on: https://go-review.googlesource.com/c/build/+/216300
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2020-01-28 16:09:18 +00:00
Dmitri Shuralyov a1b6a1b050 dashboard: remove darwin-amd64-10_8 builder type
macOS 10.8 is very old and not supported by Go 1.13 nor Go 1.12.
There are no instances of this builder type available because
macOS builders are not created on demand and the ExpectNum value
is set to zero. Remove it and various files related to it.

Fixes golang/go#36560

Change-Id: Ife36624f3695fccff2f5a12af4518e25645b4f0d
Reviewed-on: https://go-review.googlesource.com/c/build/+/215257
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2020-01-17 17:24:56 +00:00
Brad Fitzpatrick 59468795c9 cmd/rundockerbuildlet: set --security-opt=seccomp=unconfined in containers
This fixes race tests; the thread sanitizer needs to check its
personality, which seccomp defaults prevent apparently.

Updates golang/go#35547 (needs to be deployed first, then bug can be closed)

Change-Id: I8b87618f63ef2b7a75b72290098c09bf04298d86
Reviewed-on: https://go-review.googlesource.com/c/build/+/214919
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2020-01-15 18:01:19 +00:00
Dmitri Shuralyov 17a7d8724f cmd/coordinator: fix trybots for the "dl" repo, part 2
This continues the work started in CL 170417,
and hopefully finishes it.

Fixes golang/go#35581
Updates golang/go#30852

Change-Id: Ie666ead86dccb4de7dfc2ca94c79f4592b2da47a
Reviewed-on: https://go-review.googlesource.com/c/build/+/212023
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2019-12-20 00:19:08 +00:00
Dmitri Shuralyov 8a72940ee8 cmd/coordinator: use 'go tool dist test -k' on release branches
Right now, on release branches, testing is stopped very soon after
encountering the first package with a failing test. For example:

	[...]
	FAIL	cmd/go/internal/modfetch	17.181s
	ok  	cmd/go/internal/modfetch/codehost	5.474s
	FAIL
	2019/11/07 02:35:34 Failed: exit status 1

Ideally we should not have failing tests on release branches for long,
but that is not the current state. Until we reach that state, make
coordinator run 'go tool dist test' with -k flag so that it keeps
testing all remaining packages even if one fails, and report complete
test results in the log.

That way, a package that fails early doesn't make it completely
impossible to see if other package tests pass or fail.

Updates golang/go#14305
Updates golang/go#36181

Change-Id: Ia674005ae45c6b9dbffa6f5b56d60b7ed38f6b34
Reviewed-on: https://go-review.googlesource.com/c/build/+/211678
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2019-12-19 01:10:22 +00:00
Alexander Rakoczy 0bd04bf5c3 cmd/releasebot: run tests in mode=release for betas
Beta releases release from master. We cannot be certain that a change
hasn't been merged between prepare and release.

Fixes golang/go#36171

Change-Id: Ic8d043fa11259a7f8b307f6387e7b2b702ce1046
Reviewed-on: https://go-review.googlesource.com/c/build/+/211583
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2019-12-17 16:38:15 +00:00
Dmitri Shuralyov 7d6adba867 cmd/releasebot: check for Release History entry only for Go 1.12
The Release History pages have moved to x/website in CL 210797.
Checking that the current release has already been documented should
no longer happen as part of -mode=prepare for Go 1.13.x and newer.

We can consider moving this type of check into a new mode that is to be
run after a release is finished. That is discussed in golang/go#36086.

Fixes golang/go#36075
Updates golang/go#36086

Change-Id: I7547ddd4032e970ac7af1572a98698868d936a48
Reviewed-on: https://go-review.googlesource.com/c/build/+/210957
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2019-12-11 18:44:40 +00:00
Brad Fitzpatrick 773315a321 app/appengine, cmd/coordinator: fetch active builds from coordinator, avoid memcache
This implements bullets 4 and 5 from the plan to unify the dashboard &
coordinator:
https://github.com/golang/go/issues/34744#issuecomment-563398753

Previously the coordinator would POST to the dashboard regularly, for
each active build, to say "I'm still working on this build! Write that
to memcache!". And then if somebody loaded https://build.golang.org/
it would do a big memcache multi-get to populate the little blue
gopher links to their status pages on the coordinator.

This instead turns it around. We no longer POST from the coordinator
to the dashboard, and we no longer use any memcache (which also means
migrating to the App Engine Go 1.13 runtime is easier, which drops
the built-in memcache support). Instead, the dashboard now does a GET
to the coordinator to get the list of active builds.

This also adds test coverage, which we didn't have before.

Updates golang/go#34744

Change-Id: I97a486ec362a7a00d29076c81a88d6417b138c1b
Reviewed-on: https://go-review.googlesource.com/c/build/+/210838
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-12-11 17:47:50 +00:00
Alexander Rakoczy 1025632e0e internal/gophers: correct GitHub capitalization
Also updates cmd/{gomote,coordinator}, which refers to the changed
function.

Change-Id: I593f4ea1c086adaa3162ada5f39fef2265c2398e
Reviewed-on: https://go-review.googlesource.com/c/build/+/210786
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-12-10 22:44:45 +00:00
Brad Fitzpatrick e50995ec13 cmd/gerritbot: use the new repos package for repo policy
The only behavior change is that "gofrontend" is now included, which
is arguably a bug fix (an example of our various lists of repos
getting out of sync). At least, I don't recall any discussion of
omitting that repo. Ian +1'd this CL, so keeping them on.

If we want to exclude a repo from gerritbot in the future we'll need
to add some policy fields/methods to the repos package.

Updates golang/go#36047

Change-Id: I877cd3b6c292ac888863523e05799208e247499f
Reviewed-on: https://go-review.googlesource.com/c/build/+/210741
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2019-12-10 21:04:55 +00:00
Alexander Rakoczy 5e0c16c9dc cmd/gopherbot: minor follow-ups from previous CL
This change resolves outstanding comments in golang.org/cl/209717. The
import change was due to my using goimports -local.

Change-Id: I55b50166caf9ac347a11f5d3f5025860f436fc82
Reviewed-on: https://go-review.googlesource.com/c/build/+/210781
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2019-12-10 19:40:12 +00:00
Alexander Rakoczy 101a9af9cd cmd/gopherbot: improve test fake for GitHub issues
This change adds an interface and a fake implementation of a GitHub
service for labeling GitHub issues. This allows us to test more
thoroughly, as well as avoid swapping globally scoped function vars out
in tests.

There are still more places to improve testing of GitHub API calls, but
this is a start.

Change-Id: I76d007163d65e513d74c98d0211cbb92296bfa0c
Reviewed-on: https://go-review.googlesource.com/c/build/+/209717
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-12-10 18:21:55 +00:00
Brad Fitzpatrick 6e1808ab51 repos: flesh out package more, use it in maintnerd
This removes yet another list of all our repos.

(Goal is to simplify https://github.com/golang/go/wiki/CreatingSubRepository)

Most of the work was in earlier CL 208697.

Updates golang/go#36047

Change-Id: I9147b959fe6574e2f809091d08d360051b69402e
Reviewed-on: https://go-review.googlesource.com/c/build/+/210461
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2019-12-10 17:42:42 +00:00
Brad Fitzpatrick 4cca7725b4 internal/buildgo, cmd/updatedisks: clean up old, unused VM disks
After CL 210237 and CL 210541 we'd run out of disk:

    Code:QUOTA_EXCEEDED Location: Message:Quota 'SSD_TOTAL_GB' exceeded.  Limit: 8192.0 in region us-central1.

So this now cleans up old stuff.

Fixes golang/go#35987 (again)

Change-Id: I187d55209c0efb6e7b398eec7b78d0df2e7cdb2d
Reviewed-on: https://go-review.googlesource.com/c/build/+/210542
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2019-12-09 22:09:24 +00:00
Brad Fitzpatrick 326548a346 cmd/coordinator, all: fix more things related to multi-zone buildlets
This fixes stuff in CL 210498 and CL 210237.

I renamed the Zone field to ControlZone both to make it more clear and
to force compilation errors wherever Zone was used previously, which
revealed some things that were missed.

Updates golang/go#35987

Change-Id: I2f890727ece86d093a90a3b47701caa58de6ccbc
Reviewed-on: https://go-review.googlesource.com/c/build/+/210541
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2019-12-09 19:46:22 +00:00
Brad Fitzpatrick c1b987df2a cmd/gitmirror: don't keep entire maintner corpus in memory
And don't download it all on start-up.

Fixes golang/go#35977

Change-Id: I00f079d585aad8bd536a37e027fba132cc137bbd
Reviewed-on: https://go-review.googlesource.com/c/build/+/210277
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-12-09 18:21:41 +00:00
Brad Fitzpatrick c1d9249edb app/appengine, cmd/gitmirror: fix things found during deployment failure
Change-Id: I6a0ba0c50fe2b51f6a3251dcf84cca8847142150
Reviewed-on: https://go-review.googlesource.com/c/build/+/210287
Reviewed-by: Carlos Amedee <carlos@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-12-06 22:06:42 +00:00
Brad Fitzpatrick e2b9141ea8 app, gitmirror, maintner: use maintner for dashboard, not datastore
Historically, the build.golang.org was the entire build system, and it
maintained a parallel copy of that git history in its datastore. It
was always buggy and incomplete and things like force pushes were
scary because the datastore mirror could get out of sync. It was also
a lot of code to support that sync.

This changes build.golang.org to instead get the git history from
maintnerd, and then we can remove all the HTTP handlers around
updating it, and can remove all the gitmirror code to call it to
maintain it.

Now build.golang.org only keeps build results, keyed on the commit
hash. It's much less code, but is still an App Engine app for now.
(but it's getting small enough, that porting it to
cloud.google.com/go/datastore is looking very simple)

This also adds a new "repos" package to unify the configuration of the
various Go repos. There were incomplete & redundant copies all over
the place.

Updates golang/go#34744
Fixes golang/go#35828
Fixes golang/go#31236 (New branch=mixed support adds this when desired)
Fixes golang/go#35944

Change-Id: Ifb39417287df3dea052ba8510566d80b4bc75d51
Reviewed-on: https://go-review.googlesource.com/c/build/+/208697
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-12-06 21:18:41 +00:00
Carlos Amedee 96d53bbd3f cmd/coordinator: support deploying vms in multiple GCE zones
GCE zones can and will run out of resources. This will randomly
select a zone from a list of zones to deploy each new VM to.

Fixes golang/go#35987

Change-Id: I57acad5c4e81d108f7db8f5bb1ff221a1845a422
Reviewed-on: https://go-review.googlesource.com/c/build/+/210237
Run-TryBot: Carlos Amedee <carlos@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-12-06 17:33:13 +00:00
Brad Fitzpatrick 572430ca2e cmd/debugnewvm: add --zone flag
Updates golang/go#35987

Change-Id: I8338da1a317ddfb47ceafd0b22d40a21fcfb2bdd
Reviewed-on: https://go-review.googlesource.com/c/build/+/209968
Reviewed-by: Carlos Amedee <carlos@golang.org>
2019-12-05 16:01:22 +00:00
Brad Fitzpatrick a24f9651ec cmd/coordinator: make contended gomote create request cancel post-submit build
If somebody wants to "gomote create" a reverse buildlet that's busy
doing a post-submit build, the coordinator tries to find an active
non-trybot build and call (*buildStatus).cancelBuild() on it, to make
it clean up and return itself to the coordinator, so the scheduler
will get it soon and give it to the gomote user.

Fixes golang/go#35714

Change-Id: I417aead083cf3520058b3fd4d626fc385f25984e
Reviewed-on: https://go-review.googlesource.com/c/build/+/209757
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
2019-12-04 17:59:43 +00:00
Carlos Amedee 9630b08047 cmd/releasebot: correct the documentation for the gitRemoteBranchCommit function
The gitRemoteBranchCommit function documentation does not correctly
describe when the function can lead to a panic. The documentation
should state that the function will panic when the git operation fails
because of communication issues with the repository.

Change-Id: I63141d4b239946697852cd41e1b2aedaf0ad7a95
Reviewed-on: https://go-review.googlesource.com/c/build/+/208957
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2019-11-26 16:03:54 +00:00
Carlos Amedee ef1c74c627 cmd/releasebot: check that the security branch is merged into the release branch
The existing release process doesn't have any automated checks that
ensure that the changes contained in the security release branch are
in the newly created release branch. This change ensures that
non-security releases contain the HEAD commit from the security
release branch if such a branch exists.

Fixes golang/go#34505

Change-Id: I03d000177ece16548d54b6d6ad7fb0969df3946e
Reviewed-on: https://go-review.googlesource.com/c/build/+/206437
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2019-11-26 04:12:22 +00:00
Dmitri Shuralyov 77c133b63e cmd/coordinator: move remote buildlets section higher up
Right now, the "Remote buildlets" section on the farmer.golang.org
page sits below "Active Trybot Runs" and "Scheduler State".
The latter can get pretty verbose, and contains lower level
debugging information.

The "Remote buildlets" section is higher level and carries more signal,
since it's about people doing some ad-hoc work. Move it to the top so
it is easier to see (for example, when deploying cmd/coordinator).

Change-Id: I0d412dba9b679f7a03f2f2c79fc65046c3dedacd
Reviewed-on: https://go-review.googlesource.com/c/build/+/208817
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-11-25 23:11:48 +00:00
Dmitri Shuralyov dcea9574f0 cmd/gitmirror: log error details when Repo.Loop operations fail
The error value is not exposed anywhere. Start by logging it,
so that it's possible to look up the error details from logs.

Updates golang/go#35828

Change-Id: I0cfc89685269a3511c8aee767459be7a198860b1
Reviewed-on: https://go-review.googlesource.com/c/build/+/208663
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-11-25 18:51:17 +00:00
Bryan C. Mills bdcc1d0638 cmd/coordinator: use time.UTC explicitly in tests
Also use the name “now” for both the Created and Expires fields on the
remoteBuildlet message, to avoid unnecessary (and mysterious) skew if
the call happens to span a second boundary.

This fixes TestHandleBuildetCreate_Stream and
TestHandleBuildetCreate_PreStream when run on a machine with a non-UTC
local time zone.

Change-Id: I507185c758bc4fc8b1c45e181a278816ee77a337
Reviewed-on: https://go-review.googlesource.com/c/build/+/208659
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-11-25 17:42:55 +00:00
Brad Fitzpatrick 6e00cae4ea cmd/coordinator, revdial: delete the old v1 revdial code
Change-Id: I17b2e598e23112c20133d9fd0995e8bd58ff8966
Reviewed-on: https://go-review.googlesource.com/c/build/+/208598
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-25 14:51:51 +00:00
Brad Fitzpatrick 37c0486265 cmd/coordinator: give scheduler max commit date between go & x/repo commit
When testing, say, x/foo repos against master, we need to rebuild all
the x/repos whenever there's a new commit to master. For scheduling
purposes, the date that should be considered is the max of either the
x/foo commit time or the master commit time.

Change-Id: Ie8fb5f74cc5a14e5b8f7d043ddbf660248c978a6
Reviewed-on: https://go-review.googlesource.com/c/build/+/208438
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-22 18:20:09 +00:00
Brad Fitzpatrick 5dbdf0f225 cmd/coordinator: fix gomote create compatibility for older gomote clients
I broke it in CL 207841. That CL included a compatibility mode, but I
never tested it.

Fixes golang/go#35778

Change-Id: Ia0362af44c464ae2b0c786b93ed2732dfbbfe3a9
Reviewed-on: https://go-review.googlesource.com/c/build/+/208437
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Andrew Bonventre <andybons@golang.org>
2019-11-22 17:47:59 +00:00
Andrew Bonventre 48fb0f16ee cmd/release: use macOS 10.15 (Catalina) for releases
This builder has Xcode installed instead of just the command-line
tools. Because the SDKs are absent when just the command-line tools
are installed, no base SDK version is being set in the go binary
(it uses external linking) and codesign was printing a warning about
library validation. Updating to use this builder gets rid of that
warning.

Updates golang/go#35459

Change-Id: Ib548c998042f499c2d57324e9a8746594ea7060d
Reviewed-on: https://go-review.googlesource.com/c/build/+/208268
Run-TryBot: Andrew Bonventre <andybons@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Carlos Amedee <carlos@golang.org>
2019-11-22 16:41:23 +00:00
Andrew Bonventre 5de71fd729 cmd/release, cmd/releasebot: clean up unused code
+ The .pkg installer is now constructed by an internal process,
  since the binaries within the installer need to be signed using
  internal-only certs
+ 1.11 is no longer supported, so the tour is no longer shipped
  with the release

Updates golang/go#34986

Change-Id: Ic05198dec2fdbfb26d9011944051a97c777e3898
Reviewed-on: https://go-review.googlesource.com/c/build/+/208266
Run-TryBot: Andrew Bonventre <andybons@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-11-22 15:55:59 +00:00
Brad Fitzpatrick 40fd775dd0 cmd/gopherstats: change top 20->40, ignore file changes in CLs with many
Change-Id: Ic9d010cb25aa7ecd0a84531a6244b0ce3eefa0ca
Reviewed-on: https://go-review.googlesource.com/c/build/+/165038
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2019-11-21 22:23:31 +00:00
Brad Fitzpatrick 4aee3e9de4 app/appengine, cmd/genbuilderkey: move key gen from App Engine to new tool
This moves the /key handler to generate build keys to a standalone
tool. The old way has been largely broken for years (when using the
build.golang.org domain) due to internal App Engine changes. We have
to access it via https://build-dot-golang-org.appspot.com/key instead
to get authenticated.

Also, the App Engine go112 runtime doesn't support authenticated
handlers, so more reason to move off App Engine.

This CL is part of a series to move off the the build.golang.org App
Engine app that mirrors the git history into Datastore Entities, which
is full of complication and bugs.

These early steps are about removing a bunch of code from the App
Engine app so the important bits are easy to see and refactor.

Updates golang/go#34744

Change-Id: Iaf8e2bf458b5fea45bf05026d8a6eaf0ead88ec2
Reviewed-on: https://go-review.googlesource.com/c/build/+/208320
Reviewed-by: Bryan C. Mills <bcmills@google.com>
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-11-21 22:19:06 +00:00
Brad Fitzpatrick ff18cb3e05 cmd/coordinator: plumb commit time and branch from findWork down into scheduler
The branch is not yet used in this CL, but the scheduler has it now
and can use it easily in the future.

Updates golang/go#19178

Change-Id: I6abab826a8668cb091d0face8184f28d08421722
Reviewed-on: https://go-review.googlesource.com/c/build/+/208277
Reviewed-by: Bryan C. Mills <bcmills@google.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2019-11-21 16:19:56 +00:00
Carlos Amedee d6dec9c74f dashboard, cmd/makemac: add macOS 10.15 Catalina builder
Added the macOS 10.15 Catalina builder to the dashboard. Catalina builders should
use the Mojave guestid in vSphere 6.7 update 3 because the Catalina guestid is not
available in this version of vSphere. A Catalina builder will run on this version
of vSphere with the Mojave guestid. Modified the expected number of vm instances
running on Macstadium due to the addition of macOS 10.15 builders.

Updates golang/go#34748

Change-Id: If14f6e088afc05dd1783460f21907e9345e3c338
Reviewed-on: https://go-review.googlesource.com/c/build/+/207937
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2019-11-21 14:35:11 +00:00
Brad Fitzpatrick 6191a53cff cmd/coordinator, cmd/gomote: show periodic status updates to stderr
Also modernizes some code in the coordinator.

Updates golang/go#35354 (or fixes. But we could return more info.)

Change-Id: Ifc1aa85ca217a0932e388ec5d36ef0737b90c63d
Reviewed-on: https://go-review.googlesource.com/c/build/+/207841
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-20 22:32:37 +00:00
Brad Fitzpatrick d4e4f4e852 buildlet: add context argument to most of the remaining Client methods
(And update all the callers in the tree.)

Updates golang/go#35707

Change-Id: I54769bbe374f31ae1dd07776b27818db91ce8c70
Reviewed-on: https://go-review.googlesource.com/c/build/+/208157
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2019-11-20 17:29:10 +00:00
Brad Fitzpatrick 5a36865fda buildlet: add context argument to Client.Exec
(And update all the callers in the tree.)

Updates golang/go#35707

Change-Id: I504ef73ea4ba7f8028f47a658c1cd519c7b5d986
Reviewed-on: https://go-review.googlesource.com/c/build/+/207908
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2019-11-20 06:29:03 +00:00
Brad Fitzpatrick f7862f789e cmd/buildlet: advertise a hostname of "buildlet" if nothing else is set
Change-Id: I255e8feb105cee93ed65a268cd7ae0aa338ca142
Reviewed-on: https://go-review.googlesource.com/c/build/+/207557
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-20 03:06:13 +00:00
Brad Fitzpatrick e951c82c84 cmd/coordinator: implement trybot set cancellation
Fixes golang/go#35701

Change-Id: I92f7818c64cc49675f1f0a2f74533ba9558a84fd
Reviewed-on: https://go-review.googlesource.com/c/build/+/207842
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2019-11-19 23:27:54 +00:00
Carlos Amedee 77fc4b943c cmd/makemac: add macOS 10.15 Catalina as an available builder version
Makemac has been unable to create a macOS 10.15 Catalina builder. The
Catalina image is now available for creation.

Updates golang/go#34748

Change-Id: Ibc6a5f64be4de5d2eb4a89002e29944c77b6627c
Reviewed-on: https://go-review.googlesource.com/c/build/+/207737
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-11-18 21:21:03 +00:00
David du Colombier fcd348fd9e cmd/buildlet: fix removeAllIncludingReadonly on Plan 9
On Plan 9, files cannot be removed from read-only
directories.

The directories should be make writeable before
being able to remove files.

Also fixes a typo in comment.

Fixes golang/go#35634.

Change-Id: I2d810543c339e595da033e790025021e0d575b5e
Reviewed-on: https://go-review.googlesource.com/c/build/+/207283
Reviewed-by: Richard Miller <millerresearch@gmail.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-11-16 15:42:10 +00:00
Brad Fitzpatrick 4212b39061 cmd/coordinator: favor trybot work over post-submit work on process start
Updates golang/go#19178

Change-Id: I054c852db398a9474e53254c42eb5f77c44fe348
Reviewed-on: https://go-review.googlesource.com/c/build/+/207464
Reviewed-by: Bryan C. Mills <bcmills@google.com>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
2019-11-15 23:00:09 +00:00
Brad Fitzpatrick c7f36d0dc2 dashboard, env, cmd/buildlet/testssh: fix gomote ssh for a number of buidlers
And add a testssh tool to validate that SSH is working.

Updates golang/go#32430

Change-Id: I5182419fa4db31b598f7a02412fb4ecc4060a796
Reviewed-on: https://go-review.googlesource.com/c/build/+/207459
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-15 22:06:08 +00:00
Brad Fitzpatrick f0d0efff5b cmd/buildlet/stage0: simplify buildletURL lookup
Prefer explicit environment variable first, then GCE instance
attribute, then a reasonable fallback.

Change-Id: Ia034c7389de741539dcf8899e8e607fb8d09827e
Reviewed-on: https://go-review.googlesource.com/c/build/+/207460
Reviewed-by: David du Colombier <0intro@gmail.com>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-15 21:53:30 +00:00
Brad Fitzpatrick 336cc41bed cmd/buildlet: add, fix OpenBSD make targets
Updates golang/go#35610

Change-Id: I736a439df10b455125688b6c26852c366f9283fe
Reviewed-on: https://go-review.googlesource.com/c/build/+/207420
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-15 21:36:21 +00:00
Brad Fitzpatrick 7c2b75383d cmd/gomote: add gomote rdp subcommand to open an RDP proxy to a Windows buildlet
Fixes golang/go#26090

Change-Id: Ib58fb7767384778b67d0d62d34c1132d70d75c23
Reviewed-on: https://go-review.googlesource.com/c/build/+/207378
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-15 18:35:36 +00:00
Brad Fitzpatrick 4adc003e9d cmd/gomote: add --status flag to the ping subcommand
For debugging the openbsd-386 buildlet. Turns out it's ancient for some reason.

Updates golang/go#35610

Change-Id: Ie003c1b89d0c2d110bc8c70765996c7b71958779
Reviewed-on: https://go-review.googlesource.com/c/build/+/207419
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-15 17:22:22 +00:00
Brad Fitzpatrick 832e29f8f5 cmd/coordinator: omit scheduler progress times when missing or irrelevant
Updates golang/go#19178

Change-Id: Ib59eabafc589ce66948c91c7f15cbccae2d2733d
Reviewed-on: https://go-review.googlesource.com/c/build/+/207418
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-15 17:22:04 +00:00
Brad Fitzpatrick 6ff1c55858 cmd/coordinator: add buildlet TCP proxy handler, for gomote rdp
Updates golang/go#26090

Change-Id: I095f70baceb23cf28fcd70a78fd72df29603370e
Reviewed-on: https://go-review.googlesource.com/c/build/+/207357
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-15 16:32:22 +00:00
Brad Fitzpatrick 1356066394 cmd/coordinator: delete useScheduler knob & old pre-scheduler hacks, code, TODOs
Updates golang/go#19178

Change-Id: Id4d8b016c41f57bfaba5ee4ab046285607047493
Reviewed-on: https://go-review.googlesource.com/c/build/+/207178
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-14 22:33:24 +00:00
Brad Fitzpatrick 3a6724be3c cmd/coordinator: enable the scheduler
This is in its own CL for now so it's easy to revert.

Updates golang/go#19178

Change-Id: I2eb66e3c8a6e75a8039077401231577c8e7bfdc8
Reviewed-on: https://go-review.googlesource.com/c/build/+/207180
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-14 22:33:14 +00:00
Brad Fitzpatrick ead0a28fd5 cmd/coordinator: clean up HTML status, add scheduler status
The HTML status for the coordinator was way too long. For pending
builds, only show a single line, and render their state as
"waiting_for_machine" rather than "running". And for active builds,
only show the last few lines of status on the home page. People can
click for details.

Then add a scheduler status section too.

I'm also stashing away a build's SchedItem for now (with a little
refactoring to break up a long method), so a future CL can tell people
where a build is in line to get a buildlet.

Updates golang/go#19178

Change-Id: I2f37982ea3c7ee4a6581464117ae533499eba6a4
Reviewed-on: https://go-review.googlesource.com/c/build/+/207179
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-14 22:33:09 +00:00
Brad Fitzpatrick 4f37bcfff2 cmd/coordinator: add tests for the scheduler, and resulting fixes
It now passes thousands of iterations in race mode.

Updates golang/go#19178

Change-Id: I210277abd084bdfd3c7ada538189722ff9543e3f
Reviewed-on: https://go-review.googlesource.com/c/build/+/207079
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-13 22:15:01 +00:00
Rebecca Stambler 9424ac60a6 cmd/coordinator: improve formatting of builder names
This change makes sure that the name of the x/ repo is only added if the
CL is in a different repo.

Fixes golang/go#35240

Change-Id: If980b1b0a876bae1cd5ada76979deff485926258
Reviewed-on: https://go-review.googlesource.com/c/build/+/204198
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-11-13 21:43:12 +00:00
Brad Fitzpatrick fb8c09ace7 cmd/coordinator: finish the scheduler code, at least mostly
Optimizations and tuning remain, but this should be tons better than
what we had before (random).

Updates golang/go#19178

Change-Id: Idb483a4c4209a012814322cc8b37b966ee4681de
Reviewed-on: https://go-review.googlesource.com/c/build/+/205078
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-13 03:53:23 +00:00
Brad Fitzpatrick 5cfe77f6ab cmd/coordinator: don't skip x/ work on SkipSnapshot builders
Fixes golang/go#35529

Change-Id: I61a08a1cff2428751e209412502d6dba1e11e36b
Reviewed-on: https://go-review.googlesource.com/c/build/+/206797
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-11-12 17:51:26 +00:00
Brad Fitzpatrick 773364d7ec dashboard, cmd/coordinator: add linux-riscv64 builder, fix bug from CL 205608
Updates golang/go#27532
Updates golang/go#30262

Change-Id: If1593ab6e5653a9dce625f25a16bf8a082796592
Reviewed-on: https://go-review.googlesource.com/c/build/+/206639
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-11-12 06:39:49 +00:00
Bryan C. Mills 4a3109b47a cmd/fetchlogs: add a flag to fetch from non-default repos
Change-Id: Ib4c8a8ba72b7e34ae48e73187f89f9ada701ce34
Reviewed-on: https://go-review.googlesource.com/c/build/+/206417
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-11-11 15:14:40 +00:00
Milan Knezevic 912c91c6bd stage0: add support for MIPS builders to stage0
Updates golang/go#31217

Change-Id: Icf328cb39086fa4196940345c35969a8b26eafb0
Reviewed-on: https://go-review.googlesource.com/c/build/+/205797
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-11-07 18:52:39 +00:00
Brad Fitzpatrick 6d1cfead7b cmd/buildlet, cmd/coordinator: delete old --reverse mode
All the buildlets have been updated to use --reverse-type with a host
type instead of a builder type.

Fixes golang/go#21260

Change-Id: I1264261f099c3686fe01455949486f523b94c6de
Reviewed-on: https://go-review.googlesource.com/c/build/+/205608
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-06 21:01:11 +00:00
Brad Fitzpatrick d489097173 all: upgrade scaleway linux-arm builders, stop using deprecated --reverse flag
Updates golang/go#21260 (no more buildlets using the --reverse flag)
Updates golang/go#33574 (linux-arm kernel+userspace updated)

Change-Id: I7455f6fa3e851f1f9f81d6f1eb487ef7e4bea55b
Reviewed-on: https://go-review.googlesource.com/c/build/+/205603
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-06 20:48:46 +00:00
Brad Fitzpatrick 621ef1f246 cmd/coordinator: add some more checks & logging to debug Rev-less x/tools tries
Change-Id: I2fef2f01991d2942d6d9fd0bb1f335881148bc45
Reviewed-on: https://go-review.googlesource.com/c/build/+/205605
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
2019-11-06 19:55:18 +00:00
Brad Fitzpatrick 8250df6778 cmd/coordinator: truncate strings more safely
These strings should always be set, so slicing them to 8 bytes should
be fine, but apparently that's not true and the status page is
crashing when rendering the template.

Change-Id: I11b47675ca272a2e6adc6bbc496fe715e4c8c5aa
Reviewed-on: https://go-review.googlesource.com/c/build/+/205604
Reviewed-by: Carlos Amedee <carlos@golang.org>
2019-11-06 19:17:22 +00:00
Brad Fitzpatrick b8261ec315 cmd/xb, app/appengine: simplify build.golang.org deployment docs
Change-Id: I0057e5133f395de6924b94d130748db78d8b5ffc
Reviewed-on: https://go-review.googlesource.com/c/build/+/205597
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2019-11-06 16:44:19 +00:00
Brad Fitzpatrick 74c30b5b26 cmd/buildlet, cmd/makemac: stop using legacy buildlet --reverse flag for Macs
Updates golang/go#21260

Change-Id: I4e2c61117cfebffd20ab4acd3ee736172c95d153
Reviewed-on: https://go-review.googlesource.com/c/build/+/205357
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-11-05 14:48:06 +00:00
Brad Fitzpatrick b1a7aa2ef6 env/linux-ppc64/osuosl: upgrade linux/ppc64 hardware & OS, use Docker
Collaboration with @tiborvass at Docker who got Docker running on
big-endian PPC64. Go for ppc64 doesn't support cgo or external
linking, so runc doesn't work, but a new OCI-compliant runc
implementation written in C (https://github.com/containers/crun) means
we can run Docker after all. See NOTES & build-*.sh

Then add a Dockerfile & associated cleanup in buildlet & stage0 to use
rundockerbuildlet.

Once done, might help with golang/go#35188, golang/go#32613, etc.

Fixes golang/go#34830
Updates golang/go#21260

Change-Id: I43d7afa1d58bbdfa16e3c57670bc41f1d1932d80
Reviewed-on: https://go-review.googlesource.com/c/build/+/203886
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-11-04 23:54:01 +00:00
Brad Fitzpatrick 0706ea4fce cmd/coordinator: fix occasionally disappearing branch suffixes
Fixes golang/go#34234

Change-Id: I2dcd48a9e3900fad9916103737b47d945256faa7
Reviewed-on: https://go-review.googlesource.com/c/build/+/204597
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-10-31 20:22:23 +00:00
Rebecca Stambler d057d43292 cmd/coordinator: run x/tools TryBots by default on Go CLs
Fixes golang/go#34348

Change-Id: I29db60f90f4eb37a37673bb854ae215e1b0c68a9
Reviewed-on: https://go-review.googlesource.com/c/build/+/204199
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-10-31 19:01:08 +00:00
Rebecca Stambler 35df4b8c62 cmd/coordinator: add newline between also tested repo names
Change-Id: Iad4e772d61ebe8bb427e401c2a22d2948cb4d8fb
Reviewed-on: https://go-review.googlesource.com/c/build/+/204077
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-10-29 20:25:47 +00:00
Rebecca Stambler da8ade5d13 cmd/coordinator: fix formatting for x/ repo TryBots
This change also adds a test for the (*buildStatus).NameAndBranch
method. It also specifies which x/ repo TryBots ran for a given change.

Finally, it fixes the error of specifying which Go commit to run the x/
repos with.

Updates golang/go#34348

Change-Id: Ib63fa6948c3798a85174b382de38f2bc159b3347
Reviewed-on: https://go-review.googlesource.com/c/build/+/203917
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-10-28 20:18:09 +00:00
Rebecca Stambler b0cde52dd8 cmd/coordinator: add TRY=x/foo syntax for testing subrepos
This change adds support for user-invoked TryBots through the new TRY=
syntax. If the user comments TRY=x/foo on a CL to the Go repository, the
linux-amd64 builder will run at head for that repository.

Updates golang/go#34348

Change-Id: I0e7f470329866969586057501034385596e5caa0
Reviewed-on: https://go-review.googlesource.com/c/build/+/203677
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
2019-10-28 17:20:33 +00:00
Brad Fitzpatrick 34578470c8 buildlet, cmd/coordinator: stop using legacy Request.Cancel for cancellation
Maybe this will solve the golang/go#28365 problems. But at least it
gets us into codepaths that are known & trusted, and removes use of
deprecated API.

Also, add more logging to help debug golang/go#28365.

Updates golang/go#28365

Change-Id: Ibff2b03fd82573cbeedbbc22d12c30ae1a3c3aa0
Reviewed-on: https://go-review.googlesource.com/c/build/+/203217
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-10-24 19:35:26 +00:00
Brad Fitzpatrick f4570bbdcb cmd/makemac: report error if filesystem is read-only
Fixes golang/go#32449

Change-Id: I35d059778ab96ef4d57236aaccb41698314d6fac
Reviewed-on: https://go-review.googlesource.com/c/build/+/202822
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2019-10-24 15:57:58 +00:00
Dmitri Shuralyov 5ac7036ae8 cmd/gitmirror: add 10 minute timeout to git fetch
The Repo.fetch method tries to execute "git fetch" up to 3 times with
linear back-off. We don't expect the git fetch process to take more
than a few minutes unless something is very wrong. At that point,
it's better to abort and try again. So, add a 10 minute timeout.

This should help prevent fetch from being stuck and never retrying.

Fixes golang/go#35124

Change-Id: Ic06a552378f8bff1bea314288a3637548663a3ef
Reviewed-on: https://go-review.googlesource.com/c/build/+/203057
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-10-24 15:25:45 +00:00
Rebecca Stambler 6e39db66ef cmd/gopherbot: make sure gopls is in the title prefix before labeling
There have been a few instances of people reporting cmd/go issues with
gopls as an example binary that they tried to install. This leads to
issues being labeled as gopls issues, even if they are not.

Change-Id: Iead43281c4b12bebc8748057d4af7131d61d1681
Reviewed-on: https://go-review.googlesource.com/c/build/+/202297
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-10-21 21:29:37 +00:00
Brad Fitzpatrick b01e49293f cmd/coordinator: fix health checking of ppc64 machines
Fixes golang/go#34990
Updates golang/go#21189

Change-Id: I7f546564dd5149de6915dc631cafe3164e0e7a70
Reviewed-on: https://go-review.googlesource.com/c/build/+/202017
Reviewed-by: Bryan C. Mills <bcmills@google.com>
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-10-21 15:33:02 +00:00
Brad Fitzpatrick 92a45e45f1 cmd/coordinator: include command output in timeout failures
Fixes golang/go#34576

Change-Id: I77d85c311612bdbdcff665051659c2609a0af760
Reviewed-on: https://go-review.googlesource.com/c/build/+/202477
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-10-21 15:32:37 +00:00
Brad Fitzpatrick ad7af46dd4 dashboard, cmd/coordinator: move cross compilation config into dashboard package
The dashboard package has been gradually absorbing all configuration,
keeping cmd/coordinator only about mechanics. But we'd missed this
cross compilation bit in earlier cleanups.

Move it, and add some tests & docs while I'm at it.

Also, disable the linux-arm-nativemake builder by default. It's
redundant with linux-arm. They used to be more different when we
always cross compiled for linux-arm, but I guess that got disabled at
some point. At this poin it serves no purpose except as an opt-in
slowbot if the user really wants to run make.bash on scaleway.

Change-Id: Iac683ccf4d30214330480f9db39f131263b1bf8a
Reviewed-on: https://go-review.googlesource.com/c/build/+/202020
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-10-19 04:07:55 +00:00
Joshua M. Clulow f377c61833 cmd/buildlet: handle read-only directories in work area
Fixes golang/go#34980

Change-Id: I9d87e2267529212efc370ca6a858452eb829b5bb
Reviewed-on: https://go-review.googlesource.com/c/build/+/201917
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-10-18 17:32:14 +00:00
Brad Fitzpatrick aab85040a6 cmd/coordinator: add SlowBots support, opt-in to different slow trybots
This parses TRY= comments to opt-in to slower/difference trybots.

This needs some docs/UI work yet.

Updates golang/go#34501

Change-Id: I13a835520d7ac341bc86139b0a2118235bc83e60
Reviewed-on: https://go-review.googlesource.com/c/build/+/201338
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-10-18 14:56:48 +00:00
Brad Fitzpatrick c53d4ba783 all: update linux-ppc64le builders
Fixes golang/go#21189
Updates golang/go#21260
Updates golang/go#34830 (ppc64 big endian remains)

Change-Id: I7ff38edb519bf4f34cd05bb795b6a41f72b10640
Reviewed-on: https://go-review.googlesource.com/c/build/+/201637
Reviewed-by: Carlos Eduardo Seo <cseo@linux.vnet.ibm.com>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-10-17 22:31:03 +00:00
Meng Zhuo 68cf80d0b8 cmd/racebuild: add linux/arm64
Change-Id: Ieaac19bca46410a2d4f9648278a6307236d69e1e
Reviewed-on: https://go-review.googlesource.com/c/build/+/198397
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-10-17 21:59:17 +00:00
Brad Fitzpatrick f24504d3b6 all: remove use old, overloaded of IN_KUBERNETES
Fixes golang/go#34956

Change-Id: Ie6f521eee5995102d6dc13f92ecca6601a68661b
Reviewed-on: https://go-review.googlesource.com/c/build/+/201739
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-10-17 19:02:58 +00:00
Rebecca Stambler 0dcb7edcc2 cmd/gopherbot: check if bug opened by a known contributor before labeling
This change prevents GopherBot from adding a helpful comment on bugs
opened by known contributors.

Change-Id: Ibda3523d5a90e05f1eaf1be61ce555645f14e26f
Reviewed-on: https://go-review.googlesource.com/c/build/+/200762
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2019-10-16 18:45:32 +00:00
Brad Fitzpatrick 4e9e211aa5 cmd/release: don't include a godoc shortcut in Windows installer
Fixes golang/go#34892

Change-Id: I9dc14575677c3a4d75a12556896dbed340d442cc
Reviewed-on: https://go-review.googlesource.com/c/build/+/201201
Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-10-15 17:05:57 +00:00
Brad Fitzpatrick e1f196422c cmd/coordinator: make gomote proxy 502 error include detail
Go 1.11 added ReverseProxy.ErrorHandler; use it to make the
httputil.ReverseProxy failures print the underlying error back to the
(trusted) client. (Normally the client isn't necessarily trusted
enough to get the full info)

Also, log more to stderr where we can search for it.

Updates golang/go#28365

Change-Id: Iac2d863b159f24fda2e0e6e1f7374ed05434d3e4
Reviewed-on: https://go-review.googlesource.com/c/build/+/200738
Reviewed-by: Bryan C. Mills <bcmills@google.com>
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-10-11 16:47:41 +00:00
Brad Fitzpatrick b61ecd0449 dashboard, cmd/coordinator: remove Joyent builders
Joyent.com is shutting down their public cloud, so we no longer
have our GOOS=solaris or GOOS=illumos builders there.

Maybe somebody will find a new place to run them. Or maybe the ports
will be abandoned. We'll see.

Updates golang/go#15581

Change-Id: I0590227ce61b6b298b6aa4554e5e3bc9e4c464b5
Reviewed-on: https://go-review.googlesource.com/c/build/+/200219
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
2019-10-10 15:48:32 +00:00
Andrew Bonventre 6ce37fe068 cmd/coordinator: preserve test logs even if the run fails
This includes trybot runs and post-commit build runs.

Fixes golang/go#34119

Change-Id: I1d078632048c473c09a1b8581d16fd1bd65a1305
Reviewed-on: https://go-review.googlesource.com/c/build/+/198197
Run-TryBot: Andrew Bonventre <andybons@golang.org>
Reviewed-by: Alexander Rakoczy <alex@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-10-01 16:59:53 +00:00
Brad Fitzpatrick 2835ba2e68 cmd/gerritbot: strip x/foo/ PR title prefix when making commit message
Change-Id: I432a2064f6a33b3bec720a8e5cdb1cbdca1a60d8
Reviewed-on: https://go-review.googlesource.com/c/build/+/197537
Reviewed-by: Andrew Bonventre <andybons@golang.org>
Run-TryBot: Andrew Bonventre <andybons@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2019-09-27 03:13:35 +00:00
Dmitri Shuralyov bc5d3e0073 cmd/tip: use website repo on disk for installing cmd/golangorg
The 'go install golang.org/x/website/cmd/golangorg' command is being
configured with GO111MODULE=on and GOPROXY=https://proxy.golang.org
environment variables, but its directory was not set. As a result,
the main module was an empty module (GOMOD=/dev/null) instead of
the module in the website repository that was just checked out.

Set the working directory of the go install command to websiteDir,
so that the intended website module is used during the build.

Fixes golang/go#34545

Change-Id: If51030494ddb90a63b9d198209a04c5fb328784e
Reviewed-on: https://go-review.googlesource.com/c/build/+/197397
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2019-09-26 15:07:00 +00:00
Dmitri Shuralyov b0180d57c7 cmd/tip: don't install cmd/tip from the internet
Set the working directory in the Dockerfile to be inside the
golang.org/x/build module before running go install on cmd/tip.
Otherwise, it just installs the latest cmd/tip from the internet
rather than the intended local version. (All other Dockerfiles
in x/build had this line, except cmd/tip.)

Remove duplicate and unneeded WORKDIR instruction from two other
Dockerfiles to improve consistency.

Fix a rare race condition setting p.err when os.MkdirAll fails.

Add a log message when a new server has been started successfully
and the side switches. This will make logs easier to read.

Fixes golang/go#34526
Updates golang/go#34192

Change-Id: Iab8124f5c872fb87844e8e2f9b31637ce395f11b
Reviewed-on: https://go-review.googlesource.com/c/build/+/197302
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Benny Siegert <bsiegert@gmail.com>
2019-09-26 15:06:19 +00:00