Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 1 | // Copyright 2015 The Go Authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style |
| 3 | // license that can be found in the LICENSE file. |
| 4 | |
| 5 | // Package dashboard contains shared configuration and logic used by various |
| 6 | // pieces of the Go continuous build system. |
| 7 | package dashboard |
| 8 | |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 9 | import ( |
| 10 | "strconv" |
| 11 | "strings" |
Evan Brown | a731151 | 2016-02-14 15:59:59 -0800 | [diff] [blame] | 12 | |
| 13 | "golang.org/x/build/buildenv" |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 14 | ) |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 15 | |
| 16 | // Builders are the different build configurations. |
| 17 | // The keys are like "darwin-amd64" or "linux-386-387". |
| 18 | // This map should not be modified by other packages. |
| 19 | var Builders = map[string]BuildConfig{} |
| 20 | |
David Crawshaw | 66c36dd | 2015-04-23 10:23:22 -0400 | [diff] [blame] | 21 | // A BuildConfig describes how to run a builder. |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 22 | type BuildConfig struct { |
| 23 | // Name is the unique name of the builder, in the form of |
| 24 | // "darwin-386" or "linux-amd64-race". |
| 25 | Name string |
| 26 | |
David Crawshaw | 2c91215 | 2015-04-29 11:27:26 -0400 | [diff] [blame] | 27 | Notes string // notes for humans |
| 28 | Owner string // e.g. "bradfitz@golang.org", empty means golang-dev |
Joel Sing | fa600bf | 2016-01-07 23:26:09 +1100 | [diff] [blame] | 29 | VMImage string // e.g. "openbsd-amd64-58" |
Brad Fitzpatrick | 6925ce8 | 2015-09-08 15:18:47 -0700 | [diff] [blame] | 30 | KubeImage string // e.g. "linux-buildlet-std:latest" (suffix after "gcr.io/<PROJ>/") |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 31 | machineType string // optional GCE instance type |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 32 | |
| 33 | // These template URLs may contain $BUCKET which is expanded to the |
| 34 | // relevant Cloud Storage bucket as specified by the build environment. |
| 35 | goBootstrapURLTmpl string // optional URL to a built Go 1.4+ tar.gz |
| 36 | buildletURLTmpl string // optional override buildlet URL |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 37 | |
David Crawshaw | 66c36dd | 2015-04-23 10:23:22 -0400 | [diff] [blame] | 38 | IsReverse bool // if true, only use the reverse buildlet pool |
Brad Fitzpatrick | 1c6d916 | 2015-03-20 16:14:52 -0700 | [diff] [blame] | 39 | RegularDisk bool // if true, use spinning disk instead of SSD |
Brad Fitzpatrick | eb52e71 | 2015-05-13 18:38:20 -0700 | [diff] [blame] | 40 | TryOnly bool // only used for trybots, and not regular builds |
Brad Fitzpatrick | 1c6d916 | 2015-03-20 16:14:52 -0700 | [diff] [blame] | 41 | |
Brad Fitzpatrick | 79f3fc0 | 2015-05-27 21:51:25 -0700 | [diff] [blame] | 42 | // NumTestHelpers is the number of _additional_ buildlets |
| 43 | // past the first help out with sharded tests. |
| 44 | NumTestHelpers int |
| 45 | |
Brad Fitzpatrick | ac39ba8 | 2015-05-14 13:39:58 -0700 | [diff] [blame] | 46 | // BuildletType optionally specifies the type of buildlet to |
| 47 | // request from the buildlet pool. If empty, it defaults to |
| 48 | // the value of Name. |
| 49 | // |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 50 | // These should be used to minimize builder types, so the buildlet pool |
| 51 | // implementations can reuse buildlets from similar-enough builds. |
| 52 | // (e.g. a shared linux-386 trybot can be reused for some linux-amd64 |
| 53 | // or linux-amd64-race tests, etc) |
| 54 | // |
| 55 | // TODO(bradfitz): break BuildConfig up into BuildConfig and |
| 56 | // BuildletConfig and have a BuildConfig refer to a |
| 57 | // BuildletConfig. There's no much confusion now. |
Brad Fitzpatrick | ac39ba8 | 2015-05-14 13:39:58 -0700 | [diff] [blame] | 58 | BuildletType string |
| 59 | |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 60 | env []string // extra environment ("key=value") pairs |
| 61 | allScriptArgs []string |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 62 | } |
| 63 | |
Andrew Gerrand | cae837b | 2015-08-04 12:19:02 +1000 | [diff] [blame] | 64 | func (c *BuildConfig) Env() []string { |
Andrew Gerrand | 61344ad | 2015-08-04 12:43:08 +1000 | [diff] [blame] | 65 | return append([]string{"GO_BUILDER_NAME=" + c.Name}, c.env...) |
Andrew Gerrand | cae837b | 2015-08-04 12:19:02 +1000 | [diff] [blame] | 66 | } |
Brad Fitzpatrick | 32d0520 | 2015-01-21 15:15:48 -0800 | [diff] [blame] | 67 | |
Brad Fitzpatrick | f3c0193 | 2015-01-15 16:29:16 -0800 | [diff] [blame] | 68 | func (c *BuildConfig) GOOS() string { return c.Name[:strings.Index(c.Name, "-")] } |
| 69 | |
| 70 | func (c *BuildConfig) GOARCH() string { |
| 71 | arch := c.Name[strings.Index(c.Name, "-")+1:] |
| 72 | i := strings.Index(arch, "-") |
| 73 | if i == -1 { |
| 74 | return arch |
| 75 | } |
| 76 | return arch[:i] |
| 77 | } |
| 78 | |
Brad Fitzpatrick | 79f3fc0 | 2015-05-27 21:51:25 -0700 | [diff] [blame] | 79 | // FilePathJoin is mostly like filepath.Join (without the cleaning) except |
| 80 | // it uses the path separator of c.GOOS instead of the host system's. |
| 81 | func (c *BuildConfig) FilePathJoin(x ...string) string { |
| 82 | if c.GOOS() == "windows" { |
| 83 | return strings.Join(x, "\\") |
| 84 | } |
| 85 | return strings.Join(x, "/") |
| 86 | } |
| 87 | |
Brad Fitzpatrick | 50ba0cb | 2015-01-27 14:22:21 -0800 | [diff] [blame] | 88 | // BuildletBinaryURL returns the public URL of this builder's buildlet. |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 89 | func (c *BuildConfig) GoBootstrapURL(e *buildenv.Environment) string { |
| 90 | return strings.Replace(c.goBootstrapURLTmpl, "$BUCKET", e.BuildletBucket, 1) |
| 91 | } |
| 92 | |
| 93 | // BuildletBinaryURL returns the public URL of this builder's buildlet. |
Evan Brown | a731151 | 2016-02-14 15:59:59 -0800 | [diff] [blame] | 94 | func (c *BuildConfig) BuildletBinaryURL(e *buildenv.Environment) string { |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 95 | tmpl := c.buildletURLTmpl |
Evan Brown | a731151 | 2016-02-14 15:59:59 -0800 | [diff] [blame] | 96 | if tmpl == "" { |
| 97 | return "http://storage.googleapis.com/" + e.BuildletBucket + "/buildlet." + c.GOOS() + "-" + c.GOARCH() |
Brad Fitzpatrick | 50ba0cb | 2015-01-27 14:22:21 -0800 | [diff] [blame] | 98 | } |
Evan Brown | a731151 | 2016-02-14 15:59:59 -0800 | [diff] [blame] | 99 | return strings.Replace(tmpl, "$BUCKET", e.BuildletBucket, 1) |
Brad Fitzpatrick | 50ba0cb | 2015-01-27 14:22:21 -0800 | [diff] [blame] | 100 | } |
| 101 | |
Brad Fitzpatrick | a5383ff | 2015-06-17 08:22:14 -0700 | [diff] [blame] | 102 | func (c *BuildConfig) IsRace() bool { |
| 103 | return strings.HasSuffix(c.Name, "-race") |
| 104 | } |
| 105 | |
Brad Fitzpatrick | f8c2484 | 2015-01-16 09:54:03 -0800 | [diff] [blame] | 106 | // AllScript returns the relative path to the operating system's script to |
| 107 | // do the build and run its standard set of tests. |
| 108 | // Example values are "src/all.bash", "src/all.bat", "src/all.rc". |
| 109 | func (c *BuildConfig) AllScript() string { |
Brad Fitzpatrick | a5383ff | 2015-06-17 08:22:14 -0700 | [diff] [blame] | 110 | if c.IsRace() { |
Brad Fitzpatrick | 32d0520 | 2015-01-21 15:15:48 -0800 | [diff] [blame] | 111 | if strings.HasPrefix(c.Name, "windows-") { |
| 112 | return "src/race.bat" |
| 113 | } |
| 114 | return "src/race.bash" |
| 115 | } |
Brad Fitzpatrick | f8c2484 | 2015-01-16 09:54:03 -0800 | [diff] [blame] | 116 | if strings.HasPrefix(c.Name, "windows-") { |
| 117 | return "src/all.bat" |
| 118 | } |
| 119 | if strings.HasPrefix(c.Name, "plan9-") { |
| 120 | return "src/all.rc" |
| 121 | } |
Brad Fitzpatrick | 0e84fc7 | 2015-02-18 14:12:22 -0800 | [diff] [blame] | 122 | if strings.HasPrefix(c.Name, "nacl-") { |
| 123 | return "src/nacltest.bash" |
| 124 | } |
David Crawshaw | 953e869 | 2015-09-03 13:35:10 -0400 | [diff] [blame] | 125 | if strings.HasPrefix(c.Name, "android-") { |
| 126 | return "src/androidtest.bash" |
| 127 | } |
David Crawshaw | e078c6f | 2015-04-29 08:54:19 -0400 | [diff] [blame] | 128 | if strings.HasPrefix(c.Name, "darwin-arm") { |
| 129 | return "src/iostest.bash" |
| 130 | } |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 131 | if c.Name == "misc-compile" { |
Brad Fitzpatrick | ab7ff8a | 2015-04-29 14:44:46 -0700 | [diff] [blame] | 132 | return "src/buildall.bash" |
| 133 | } |
Brad Fitzpatrick | f8c2484 | 2015-01-16 09:54:03 -0800 | [diff] [blame] | 134 | return "src/all.bash" |
| 135 | } |
| 136 | |
Brad Fitzpatrick | 7d9b036 | 2015-05-27 11:51:27 -0700 | [diff] [blame] | 137 | // SplitMakeRun reports whether the coordinator should first compile |
| 138 | // (using c.MakeScript), then snapshot, then run the tests (ideally |
| 139 | // sharded) using c.RunScript. |
| 140 | // Eventually this function should always return true (and then be deleted) |
| 141 | // but for now we've only set up the scripts and verified that the main |
| 142 | // configurations work. |
| 143 | func (c *BuildConfig) SplitMakeRun() bool { |
| 144 | switch c.AllScript() { |
Brad Fitzpatrick | a5383ff | 2015-06-17 08:22:14 -0700 | [diff] [blame] | 145 | case "src/all.bash", "src/race.bash", "src/all.bat", "src/all.rc": |
Brad Fitzpatrick | 7d9b036 | 2015-05-27 11:51:27 -0700 | [diff] [blame] | 146 | // These we've verified to work. |
| 147 | return true |
| 148 | } |
| 149 | // Conservatively: |
| 150 | return false |
| 151 | } |
| 152 | |
Andrew Gerrand | 234725b | 2015-06-04 16:45:17 -0700 | [diff] [blame] | 153 | func (c *BuildConfig) BuildSubrepos() bool { |
| 154 | if !c.SplitMakeRun() { |
| 155 | return false |
| 156 | } |
Andrew Gerrand | af7d181 | 2015-06-11 10:01:24 -0700 | [diff] [blame] | 157 | // TODO(adg,bradfitz): expand this as required |
| 158 | switch c.Name { |
| 159 | case "darwin-amd64-10_10", |
| 160 | "freebsd-386-gce101", "freebsd-amd64-gce101", |
| 161 | "linux-386", "linux-amd64", "linux-amd64-nocgo", |
Joel Sing | fa600bf | 2016-01-07 23:26:09 +1100 | [diff] [blame] | 162 | "openbsd-386-gce58", "openbsd-amd64-gce58", |
Andrew Gerrand | af7d181 | 2015-06-11 10:01:24 -0700 | [diff] [blame] | 163 | "plan9-386", |
| 164 | "windows-386-gce", "windows-amd64-gce": |
| 165 | return true |
| 166 | default: |
| 167 | return false |
| 168 | } |
Andrew Gerrand | 234725b | 2015-06-04 16:45:17 -0700 | [diff] [blame] | 169 | } |
| 170 | |
Andrew Gerrand | fb77488 | 2015-05-21 14:02:38 +1000 | [diff] [blame] | 171 | // AllScriptArgs returns the set of arguments that should be passed to the |
David Crawshaw | e078c6f | 2015-04-29 08:54:19 -0400 | [diff] [blame] | 172 | // all.bash-equivalent script. Usually empty. |
| 173 | func (c *BuildConfig) AllScriptArgs() []string { |
| 174 | if strings.HasPrefix(c.Name, "darwin-arm") { |
| 175 | return []string{"-restart"} |
| 176 | } |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 177 | return append([]string(nil), c.allScriptArgs...) |
David Crawshaw | e078c6f | 2015-04-29 08:54:19 -0400 | [diff] [blame] | 178 | } |
| 179 | |
Andrew Gerrand | f83f3e4 | 2015-02-02 12:05:01 +0000 | [diff] [blame] | 180 | // MakeScript returns the relative path to the operating system's script to |
| 181 | // do the build. |
| 182 | // Example values are "src/make.bash", "src/make.bat", "src/make.rc". |
| 183 | func (c *BuildConfig) MakeScript() string { |
| 184 | if strings.HasPrefix(c.Name, "windows-") { |
| 185 | return "src/make.bat" |
| 186 | } |
| 187 | if strings.HasPrefix(c.Name, "plan9-") { |
| 188 | return "src/make.rc" |
| 189 | } |
| 190 | return "src/make.bash" |
| 191 | } |
| 192 | |
Andrew Gerrand | fb77488 | 2015-05-21 14:02:38 +1000 | [diff] [blame] | 193 | // MakeScriptArgs returns the set of arguments that should be passed to the |
| 194 | // make.bash-equivalent script. Usually empty. |
| 195 | func (c *BuildConfig) MakeScriptArgs() []string { |
| 196 | return c.AllScriptArgs() |
| 197 | } |
| 198 | |
| 199 | // RunScript returns the relative path to the operating system's script to |
| 200 | // run the test suite. |
| 201 | // Example values are "src/run.bash", "src/run.bat", "src/run.rc". |
| 202 | func (c *BuildConfig) RunScript() string { |
| 203 | if strings.HasPrefix(c.Name, "windows-") { |
| 204 | return "src/run.bat" |
| 205 | } |
| 206 | if strings.HasPrefix(c.Name, "plan9-") { |
| 207 | return "src/run.rc" |
| 208 | } |
| 209 | return "src/run.bash" |
| 210 | } |
| 211 | |
| 212 | // RunScriptArgs returns the set of arguments that should be passed to the |
| 213 | // run.bash-equivalent script. |
| 214 | func (c *BuildConfig) RunScriptArgs() []string { |
| 215 | return []string{"--no-rebuild"} |
| 216 | } |
| 217 | |
Andrew Gerrand | f83f3e4 | 2015-02-02 12:05:01 +0000 | [diff] [blame] | 218 | // GorootFinal returns the default install location for |
| 219 | // releases for this platform. |
| 220 | func (c *BuildConfig) GorootFinal() string { |
| 221 | if strings.HasPrefix(c.Name, "windows-") { |
| 222 | return "c:\\go" |
| 223 | } |
| 224 | return "/usr/local/go" |
| 225 | } |
| 226 | |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 227 | // MachineType returns the GCE machine type to use for this builder. |
| 228 | func (c *BuildConfig) MachineType() string { |
| 229 | if v := c.machineType; v != "" { |
| 230 | return v |
| 231 | } |
| 232 | return "n1-highcpu-2" |
| 233 | } |
| 234 | |
David Crawshaw | eef380f | 2015-04-30 20:03:01 -0400 | [diff] [blame] | 235 | // ShortOwner returns a short human-readable owner. |
| 236 | func (c BuildConfig) ShortOwner() string { |
| 237 | if c.Owner == "" { |
| 238 | return "go-dev" |
| 239 | } |
| 240 | return strings.TrimSuffix(c.Owner, "@golang.org") |
| 241 | } |
| 242 | |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 243 | // GCENumCPU reports the number of GCE CPUs this buildlet requires. |
| 244 | func (c *BuildConfig) GCENumCPU() int { |
| 245 | t := c.MachineType() |
| 246 | n, _ := strconv.Atoi(t[strings.LastIndex(t, "-")+1:]) |
| 247 | return n |
| 248 | } |
| 249 | |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 250 | func init() { |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 251 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 252 | Name: "freebsd-amd64-gce93", |
| 253 | VMImage: "freebsd-amd64-gce93", |
| 254 | machineType: "n1-highcpu-2", |
| 255 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-freebsd-amd64.tar.gz", |
| 256 | NumTestHelpers: 3, |
Bill Thiede | 222a9c0 | 2015-01-21 21:16:54 -0800 | [diff] [blame] | 257 | }) |
| 258 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 259 | Name: "freebsd-amd64-gce101", |
| 260 | Notes: "FreeBSD 10.1; GCE VM is built from script in build/env/freebsd-amd64", |
| 261 | VMImage: "freebsd-amd64-gce101", |
| 262 | machineType: "n1-highcpu-2", |
| 263 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-freebsd-amd64.tar.gz", |
| 264 | env: []string{"CC=clang"}, |
| 265 | NumTestHelpers: 3, |
Brad Fitzpatrick | 32d0520 | 2015-01-21 15:15:48 -0800 | [diff] [blame] | 266 | }) |
| 267 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 268 | Name: "freebsd-amd64-race", |
| 269 | VMImage: "freebsd-amd64-gce101", |
| 270 | machineType: "n1-highcpu-4", |
| 271 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-freebsd-amd64.tar.gz", |
| 272 | env: []string{"CC=clang"}, |
Brad Fitzpatrick | 32d0520 | 2015-01-21 15:15:48 -0800 | [diff] [blame] | 273 | }) |
| 274 | addBuilder(BuildConfig{ |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 275 | Name: "freebsd-386-gce101", |
| 276 | VMImage: "freebsd-amd64-gce101", |
| 277 | //BuildletType: "freebsd-amd64-gce101", |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 278 | machineType: "n1-highcpu-2", |
| 279 | buildletURLTmpl: "http://storage.googleapis.com/$BUCKET/buildlet.freebsd-amd64", |
| 280 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-freebsd-amd64.tar.gz", |
| 281 | env: []string{"GOARCH=386", "GOHOSTARCH=386", "CC=clang"}, |
| 282 | NumTestHelpers: 3, |
Brad Fitzpatrick | 50ba0cb | 2015-01-27 14:22:21 -0800 | [diff] [blame] | 283 | }) |
| 284 | addBuilder(BuildConfig{ |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 285 | Name: "linux-386", |
| 286 | VMImage: "linux-buildlet-std", |
| 287 | //BuildletType: "linux-amd64", |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 288 | buildletURLTmpl: "http://storage.googleapis.com/$BUCKET/buildlet.linux-amd64", |
| 289 | env: []string{"GOROOT_BOOTSTRAP=/go1.4", "GOARCH=386", "GOHOSTARCH=386"}, |
| 290 | NumTestHelpers: 3, |
Brad Fitzpatrick | 50ba0cb | 2015-01-27 14:22:21 -0800 | [diff] [blame] | 291 | }) |
| 292 | addBuilder(BuildConfig{ |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 293 | Name: "linux-386-387", |
| 294 | Notes: "GO386=387", |
| 295 | VMImage: "linux-buildlet-std", |
| 296 | //BuildletType: "linux-amd64", |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 297 | buildletURLTmpl: "http://storage.googleapis.com/$BUCKET/buildlet.linux-amd64", |
| 298 | env: []string{"GOROOT_BOOTSTRAP=/go1.4", "GOARCH=386", "GOHOSTARCH=386", "GO386=387"}, |
Brad Fitzpatrick | 50ba0cb | 2015-01-27 14:22:21 -0800 | [diff] [blame] | 299 | }) |
| 300 | addBuilder(BuildConfig{ |
Brad Fitzpatrick | 79f3fc0 | 2015-05-27 21:51:25 -0700 | [diff] [blame] | 301 | Name: "linux-amd64", |
| 302 | VMImage: "linux-buildlet-std", |
| 303 | env: []string{"GOROOT_BOOTSTRAP=/go1.4"}, |
| 304 | NumTestHelpers: 3, |
Brad Fitzpatrick | 50ba0cb | 2015-01-27 14:22:21 -0800 | [diff] [blame] | 305 | }) |
| 306 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 307 | Name: "linux-amd64-kube", |
| 308 | KubeImage: "linux-x86-std:latest", |
| 309 | buildletURLTmpl: "http://storage.googleapis.com/$BUCKET/buildlet.linux-amd64", |
| 310 | env: []string{"GOROOT_BOOTSTRAP=/go1.4"}, |
| 311 | NumTestHelpers: 3, |
Evan Brown | 08b68a9 | 2015-11-20 10:00:06 -0800 | [diff] [blame] | 312 | }) |
| 313 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 314 | Name: "misc-compile", |
| 315 | TryOnly: true, |
| 316 | VMImage: "linux-buildlet-std", |
| 317 | machineType: "n1-highcpu-16", // CPU-bound, uses it well. |
| 318 | Notes: "Runs buildall.sh to compile stdlib for GOOS/GOARCH pairs not otherwise covered by trybots, but doesn't run any tests.", |
| 319 | buildletURLTmpl: "http://storage.googleapis.com/$BUCKET/buildlet.linux-amd64", |
| 320 | env: []string{"GOROOT_BOOTSTRAP=/go1.4"}, |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 321 | allScriptArgs: []string{ |
| 322 | // Filtering pattern to buildall.bash: |
Shenghou Ma | 465e286 | 2016-01-18 23:29:49 -0500 | [diff] [blame] | 323 | "^(linux-arm64|linux-ppc64|linux-ppc64le|linux-mips.*|nacl-arm|plan9-amd64|solaris-amd64|netbsd-386|netbsd-amd64|netbsd-arm|freebsd-arm|darwin-386)$", |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 324 | }, |
Brad Fitzpatrick | ab7ff8a | 2015-04-29 14:44:46 -0700 | [diff] [blame] | 325 | }) |
| 326 | addBuilder(BuildConfig{ |
Brad Fitzpatrick | 50ba0cb | 2015-01-27 14:22:21 -0800 | [diff] [blame] | 327 | Name: "linux-amd64-nocgo", |
David Crawshaw | 2c91215 | 2015-04-29 11:27:26 -0400 | [diff] [blame] | 328 | Notes: "cgo disabled", |
Brad Fitzpatrick | 50ba0cb | 2015-01-27 14:22:21 -0800 | [diff] [blame] | 329 | VMImage: "linux-buildlet-std", |
| 330 | env: []string{ |
| 331 | "GOROOT_BOOTSTRAP=/go1.4", |
| 332 | "CGO_ENABLED=0", |
| 333 | // This USER=root was required for Docker-based builds but probably isn't required |
| 334 | // in the VM anymore, since the buildlet probably already has this in its environment. |
| 335 | // (It was required because without cgo, it couldn't find the username) |
| 336 | "USER=root", |
| 337 | }, |
| 338 | }) |
| 339 | addBuilder(BuildConfig{ |
| 340 | Name: "linux-amd64-noopt", |
David Crawshaw | 2c91215 | 2015-04-29 11:27:26 -0400 | [diff] [blame] | 341 | Notes: "optimizations and inlining disabled", |
Brad Fitzpatrick | 50ba0cb | 2015-01-27 14:22:21 -0800 | [diff] [blame] | 342 | VMImage: "linux-buildlet-std", |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 343 | //BuildletType: "linux-amd64", |
| 344 | env: []string{"GOROOT_BOOTSTRAP=/go1.4", "GO_GCFLAGS=-N -l"}, |
Brad Fitzpatrick | 50ba0cb | 2015-01-27 14:22:21 -0800 | [diff] [blame] | 345 | }) |
| 346 | addBuilder(BuildConfig{ |
Keith Randall | a04c813 | 2016-03-18 15:30:38 -0700 | [diff] [blame] | 347 | Name: "linux-amd64-ssacheck", |
| 348 | Notes: "SSA internal checks enabled", |
| 349 | VMImage: "linux-buildlet-std", |
| 350 | //BuildletType: "linux-amd64", |
| 351 | env: []string{"GOROOT_BOOTSTRAP=/go1.4", "GO_GCFLAGS=-d=ssa/check/on"}, |
| 352 | }) |
| 353 | addBuilder(BuildConfig{ |
Brad Fitzpatrick | a5383ff | 2015-06-17 08:22:14 -0700 | [diff] [blame] | 354 | Name: "linux-amd64-race", |
| 355 | VMImage: "linux-buildlet-std", |
| 356 | machineType: "n1-highcpu-4", |
| 357 | env: []string{"GOROOT_BOOTSTRAP=/go1.4"}, |
| 358 | NumTestHelpers: 4, |
Brad Fitzpatrick | 32d0520 | 2015-01-21 15:15:48 -0800 | [diff] [blame] | 359 | }) |
| 360 | addBuilder(BuildConfig{ |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 361 | Name: "linux-386-clang", |
| 362 | VMImage: "linux-buildlet-clang", |
| 363 | //BuildletType: "linux-amd64-clang", |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 364 | buildletURLTmpl: "http://storage.googleapis.com/$BUCKET/buildlet.linux-amd64", |
| 365 | env: []string{"GOROOT_BOOTSTRAP=/go1.4", "CC=/usr/bin/clang", "GOHOSTARCH=386"}, |
Brad Fitzpatrick | a0a155e | 2015-02-12 19:45:02 -0800 | [diff] [blame] | 366 | }) |
| 367 | addBuilder(BuildConfig{ |
| 368 | Name: "linux-amd64-clang", |
David Crawshaw | 2c91215 | 2015-04-29 11:27:26 -0400 | [diff] [blame] | 369 | Notes: "Debian wheezy + clang 3.5 instead of gcc", |
Brad Fitzpatrick | a0a155e | 2015-02-12 19:45:02 -0800 | [diff] [blame] | 370 | VMImage: "linux-buildlet-clang", |
| 371 | env: []string{"GOROOT_BOOTSTRAP=/go1.4", "CC=/usr/bin/clang"}, |
| 372 | }) |
| 373 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 374 | Name: "linux-386-sid", |
| 375 | VMImage: "linux-buildlet-sid", |
| 376 | buildletURLTmpl: "http://storage.googleapis.com/$BUCKET/buildlet.linux-amd64", |
| 377 | env: []string{"GOROOT_BOOTSTRAP=/go1.4", "GOHOSTARCH=386"}, |
Brad Fitzpatrick | f0728e3 | 2015-02-13 19:01:32 -0800 | [diff] [blame] | 378 | }) |
| 379 | addBuilder(BuildConfig{ |
| 380 | Name: "linux-amd64-sid", |
David Crawshaw | 2c91215 | 2015-04-29 11:27:26 -0400 | [diff] [blame] | 381 | Notes: "Debian sid (unstable)", |
Brad Fitzpatrick | f0728e3 | 2015-02-13 19:01:32 -0800 | [diff] [blame] | 382 | VMImage: "linux-buildlet-sid", |
| 383 | env: []string{"GOROOT_BOOTSTRAP=/go1.4"}, |
| 384 | }) |
| 385 | addBuilder(BuildConfig{ |
Brad Fitzpatrick | 1f0d8f2 | 2015-09-14 18:33:55 +0000 | [diff] [blame] | 386 | Name: "linux-arm", |
| 387 | IsReverse: true, |
| 388 | NumTestHelpers: 6, |
| 389 | env: []string{"GOROOT_BOOTSTRAP=/usr/local/go"}, |
Brad Fitzpatrick | dfe8286 | 2015-03-01 09:23:57 -0800 | [diff] [blame] | 390 | }) |
| 391 | addBuilder(BuildConfig{ |
Brad Fitzpatrick | f319bb6 | 2015-05-07 11:36:25 -0700 | [diff] [blame] | 392 | Name: "linux-arm-arm5", |
| 393 | IsReverse: true, |
Brad Fitzpatrick | 1c43756 | 2015-05-11 08:47:37 -0700 | [diff] [blame] | 394 | env: []string{ |
| 395 | "GOROOT_BOOTSTRAP=/usr/local/go", |
Brad Fitzpatrick | bab0718 | 2015-05-13 15:16:31 -0700 | [diff] [blame] | 396 | "GOARM=5", |
Brad Fitzpatrick | 1c43756 | 2015-05-11 08:47:37 -0700 | [diff] [blame] | 397 | "GO_TEST_TIMEOUT_SCALE=5", // slow. |
| 398 | }, |
Brad Fitzpatrick | f319bb6 | 2015-05-07 11:36:25 -0700 | [diff] [blame] | 399 | }) |
| 400 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 401 | Name: "nacl-386", |
| 402 | VMImage: "linux-buildlet-nacl-v2", |
| 403 | buildletURLTmpl: "http://storage.googleapis.com/$BUCKET/buildlet.linux-amd64", |
| 404 | env: []string{"GOROOT_BOOTSTRAP=/go1.4", "GOOS=nacl", "GOARCH=386", "GOHOSTOS=linux", "GOHOSTARCH=amd64"}, |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 405 | //BuildletType: "nacl-amd64p32", |
Brad Fitzpatrick | 0e84fc7 | 2015-02-18 14:12:22 -0800 | [diff] [blame] | 406 | }) |
| 407 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 408 | Name: "nacl-amd64p32", |
| 409 | VMImage: "linux-buildlet-nacl-v2", |
| 410 | buildletURLTmpl: "http://storage.googleapis.com/$BUCKET/buildlet.linux-amd64", |
| 411 | env: []string{"GOROOT_BOOTSTRAP=/go1.4", "GOOS=nacl", "GOARCH=amd64p32", "GOHOSTOS=linux", "GOHOSTARCH=amd64"}, |
Brad Fitzpatrick | 0e84fc7 | 2015-02-18 14:12:22 -0800 | [diff] [blame] | 412 | }) |
| 413 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 414 | Name: "nacl-386-kube", |
| 415 | KubeImage: "linux-x86-nacl:latest", |
| 416 | buildletURLTmpl: "http://storage.googleapis.com/$BUCKET/buildlet.linux-amd64", |
| 417 | env: []string{"GOROOT_BOOTSTRAP=/go1.4", "GOOS=nacl", "GOARCH=386", "GOHOSTOS=linux", "GOHOSTARCH=amd64"}, |
Evan Brown | 6cd016f | 2016-01-26 15:13:47 -0800 | [diff] [blame] | 418 | }) |
| 419 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 420 | Name: "nacl-amd64p32-kube", |
| 421 | KubeImage: "linux-x86-nacl:latest", |
| 422 | buildletURLTmpl: "http://storage.googleapis.com/$BUCKET/buildlet.linux-amd64", |
| 423 | env: []string{"GOROOT_BOOTSTRAP=/go1.4", "GOOS=nacl", "GOARCH=amd64p32", "GOHOSTOS=linux", "GOHOSTARCH=amd64"}, |
Evan Brown | 6cd016f | 2016-01-26 15:13:47 -0800 | [diff] [blame] | 424 | }) |
| 425 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 426 | Name: "openbsd-amd64-gce58", |
| 427 | Notes: "OpenBSD 5.8; GCE VM is built from script in build/env/openbsd-amd64", |
| 428 | VMImage: "openbsd-amd64-58", |
| 429 | machineType: "n1-highcpu-2", |
| 430 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-openbsd-amd64-gce58.tar.gz", |
| 431 | NumTestHelpers: 3, |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 432 | }) |
| 433 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 434 | Name: "openbsd-386-gce58", |
| 435 | Notes: "OpenBSD 5.8; GCE VM is built from script in build/env/openbsd-386", |
| 436 | VMImage: "openbsd-386-58", |
| 437 | machineType: "n1-highcpu-2", |
| 438 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-openbsd-386-gce58.tar.gz", |
| 439 | NumTestHelpers: 3, |
Brad Fitzpatrick | f6a4a4a | 2015-01-22 14:11:10 -0800 | [diff] [blame] | 440 | }) |
| 441 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 442 | Name: "plan9-386", |
| 443 | Notes: "Plan 9 from 0intro; GCE VM is built from script in build/env/plan9-386", |
| 444 | VMImage: "plan9-386-v2", |
| 445 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-plan9-386.tar.gz", |
Brad Fitzpatrick | 32d0520 | 2015-01-21 15:15:48 -0800 | [diff] [blame] | 446 | |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 447 | // We *were* using n1-standard-1 because Plan 9 can only |
| 448 | // reliably use a single CPU. Using 2 or 4 and we see |
| 449 | // test failures. See: |
| 450 | // https://golang.org/issue/8393 |
| 451 | // https://golang.org/issue/9491 |
Brad Fitzpatrick | dfe8286 | 2015-03-01 09:23:57 -0800 | [diff] [blame] | 452 | // n1-standard-1 has 3.6 GB of memory which WAS (see below) |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 453 | // overkill (userspace probably only sees 2GB anyway), |
| 454 | // but it's the cheapest option. And plenty to keep |
| 455 | // our ~250 MB of inputs+outputs in its ramfs. |
| 456 | // |
| 457 | // But the docs says "For the n1 series of machine |
| 458 | // types, a virtual CPU is implemented as a single |
| 459 | // hyperthread on a 2.6GHz Intel Sandy Bridge Xeon or |
| 460 | // Intel Ivy Bridge Xeon (or newer) processor. This |
| 461 | // means that the n1-standard-2 machine type will see |
| 462 | // a whole physical core." |
| 463 | // |
Brad Fitzpatrick | dfe8286 | 2015-03-01 09:23:57 -0800 | [diff] [blame] | 464 | // ... so we used n1-highcpu-2 (1.80 RAM, still |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 465 | // plenty), just so we can get 1 whole core for the |
| 466 | // single-core Plan 9. It will see 2 virtual cores and |
| 467 | // only use 1, but we hope that 1 will be more powerful |
| 468 | // and we'll stop timing out on tests. |
David du Colombier | 6ff9135 | 2015-08-05 13:52:50 +0200 | [diff] [blame] | 469 | machineType: "n1-highcpu-4", |
Brad Fitzpatrick | 79f3fc0 | 2015-05-27 21:51:25 -0700 | [diff] [blame] | 470 | |
| 471 | NumTestHelpers: 5, // slow |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 472 | }) |
Brad Fitzpatrick | cc587d4 | 2015-02-06 17:32:15 -0800 | [diff] [blame] | 473 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 474 | Name: "windows-amd64-gce", |
| 475 | VMImage: "windows-buildlet-v2", |
| 476 | machineType: "n1-highcpu-2", |
| 477 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-windows-amd64.tar.gz", |
| 478 | RegularDisk: true, |
| 479 | env: []string{"GOARCH=amd64", "GOHOSTARCH=amd64"}, |
| 480 | NumTestHelpers: 3, |
Brad Fitzpatrick | cc587d4 | 2015-02-06 17:32:15 -0800 | [diff] [blame] | 481 | }) |
| 482 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 483 | Name: "windows-amd64-race", |
| 484 | Notes: "Only runs -race tests (./race.bat)", |
| 485 | VMImage: "windows-buildlet-v2", |
| 486 | machineType: "n1-highcpu-4", |
| 487 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-windows-amd64.tar.gz", |
| 488 | RegularDisk: true, |
| 489 | env: []string{"GOARCH=amd64", "GOHOSTARCH=amd64"}, |
Brad Fitzpatrick | cc587d4 | 2015-02-06 17:32:15 -0800 | [diff] [blame] | 490 | }) |
| 491 | addBuilder(BuildConfig{ |
Brad Fitzpatrick | 1b1e086 | 2015-06-04 18:25:50 -0700 | [diff] [blame] | 492 | Name: "windows-386-gce", |
| 493 | VMImage: "windows-buildlet-v2", |
| 494 | machineType: "n1-highcpu-2", |
| 495 | // TODO(bradfitz): once buildlet type vs. config type is split: BuildletType: "windows-amd64-gce", |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 496 | buildletURLTmpl: "http://storage.googleapis.com/$BUCKET/buildlet.windows-amd64", |
| 497 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-windows-386.tar.gz", |
| 498 | RegularDisk: true, |
| 499 | env: []string{"GOARCH=386", "GOHOSTARCH=386"}, |
| 500 | NumTestHelpers: 3, |
Brad Fitzpatrick | cc587d4 | 2015-02-06 17:32:15 -0800 | [diff] [blame] | 501 | }) |
David Crawshaw | 66c36dd | 2015-04-23 10:23:22 -0400 | [diff] [blame] | 502 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 503 | Name: "darwin-amd64-10_10", |
| 504 | Notes: "Mac Mini running OS X 10.10 (Yosemite)", |
| 505 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-darwin-amd64.tar.gz", |
| 506 | IsReverse: true, |
| 507 | NumTestHelpers: 0, // disabled per golang.org/issue/12979 |
David Crawshaw | 66c36dd | 2015-04-23 10:23:22 -0400 | [diff] [blame] | 508 | }) |
David Crawshaw | e078c6f | 2015-04-29 08:54:19 -0400 | [diff] [blame] | 509 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 510 | Name: "darwin-386-10_10", |
| 511 | Notes: "Mac Mini running OS X 10.10 (Yosemite)", |
| 512 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-darwin-amd64.tar.gz", |
| 513 | IsReverse: true, |
| 514 | env: []string{"GOARCH=386", "GOHOSTARCH=386"}, |
| 515 | NumTestHelpers: 0, // disabled per golang.org/issue/12979 |
David Crawshaw | e29c0bb | 2015-07-22 10:54:18 -0400 | [diff] [blame] | 516 | }) |
| 517 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 518 | Name: "android-arm-sdk19", |
| 519 | Notes: "Android ARM device running android-19 (KitKat 4.4), attatched to Mac Mini", |
| 520 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-darwin-amd64.tar.gz", |
| 521 | IsReverse: true, |
| 522 | env: []string{"GOOS=android", "GOARCH=arm"}, |
| 523 | NumTestHelpers: 1, // limited resources |
David Crawshaw | e29c0bb | 2015-07-22 10:54:18 -0400 | [diff] [blame] | 524 | }) |
| 525 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 526 | Name: "android-arm64-sdk21", |
| 527 | Notes: "Android arm64 device using the android-21 toolchain, attatched to Mac Mini", |
| 528 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-darwin-amd64.tar.gz", |
| 529 | IsReverse: true, |
| 530 | env: []string{"GOOS=android", "GOARCH=arm64"}, |
| 531 | NumTestHelpers: 1, // limited resources |
David Crawshaw | 1a1fe1e | 2015-11-20 11:08:04 -0500 | [diff] [blame] | 532 | }) |
| 533 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 534 | Name: "android-386-sdk21", |
| 535 | Notes: "Android 386 device using the android-21 toolchain, attatched to Mac Mini", |
| 536 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-darwin-amd64.tar.gz", |
| 537 | IsReverse: true, |
| 538 | env: []string{"GOOS=android", "GOARCH=386"}, |
| 539 | NumTestHelpers: 1, // limited resources |
David Crawshaw | 1a1fe1e | 2015-11-20 11:08:04 -0500 | [diff] [blame] | 540 | }) |
| 541 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 542 | Name: "android-amd64-sdk21", |
| 543 | Notes: "Android amd64 device using the android-21 toolchain, attatched to Mac Mini", |
| 544 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-darwin-amd64.tar.gz", |
| 545 | IsReverse: true, |
| 546 | env: []string{"GOOS=android", "GOARCH=amd64"}, |
| 547 | NumTestHelpers: 1, // limited resources |
David Crawshaw | 1a1fe1e | 2015-11-20 11:08:04 -0500 | [diff] [blame] | 548 | }) |
| 549 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 550 | Name: "darwin-arm-a5ios", |
| 551 | Notes: "iPhone 4S (A5 processor), via a Mac Mini", |
| 552 | Owner: "crawshaw@golang.org", |
| 553 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-darwin-amd64.tar.gz", |
| 554 | IsReverse: true, |
| 555 | env: []string{"GOARCH=arm", "GOHOSTARCH=amd64"}, |
David Crawshaw | e078c6f | 2015-04-29 08:54:19 -0400 | [diff] [blame] | 556 | }) |
David Crawshaw | e078c6f | 2015-04-29 08:54:19 -0400 | [diff] [blame] | 557 | addBuilder(BuildConfig{ |
Andrew Gerrand | 8e28dc9 | 2016-03-22 09:05:52 +1100 | [diff] [blame^] | 558 | Name: "darwin-arm64-a7ios", |
| 559 | Notes: "iPad Mini 3 (A7 processor), via a Mac Mini", |
| 560 | Owner: "crawshaw@golang.org", |
| 561 | goBootstrapURLTmpl: "https://storage.googleapis.com/$BUCKET/go1.4-darwin-amd64.tar.gz", |
| 562 | IsReverse: true, |
| 563 | env: []string{"GOARCH=arm64", "GOHOSTARCH=amd64"}, |
David Crawshaw | e078c6f | 2015-04-29 08:54:19 -0400 | [diff] [blame] | 564 | }) |
Brad Fitzpatrick | c2a36fd | 2016-03-01 04:49:24 +0000 | [diff] [blame] | 565 | addBuilder(BuildConfig{ |
| 566 | Name: "solaris-amd64-smartosbuildlet", |
| 567 | Notes: "run by Go team on Joyent, on a SmartOS 'infrastructure container'", |
| 568 | IsReverse: true, |
| 569 | NumTestHelpers: 0, |
| 570 | env: []string{"GOROOT_BOOTSTRAP=/root/go-solaris-amd64-bootstrap"}, |
| 571 | }) |
| 572 | addBuilder(BuildConfig{ |
| 573 | Name: "linux-ppc64le-buildlet", |
| 574 | Notes: "Debian jessie; run by Go team on osuosl.org", |
| 575 | IsReverse: true, |
| 576 | NumTestHelpers: 0, |
| 577 | env: []string{"GOROOT_BOOTSTRAP=/home/debian/go-linux-ppc64le-bootstrap"}, |
| 578 | }) |
| 579 | addBuilder(BuildConfig{ |
| 580 | Name: "linux-s390x-ibm", |
| 581 | Notes: "run by IBM", |
| 582 | IsReverse: true, |
| 583 | NumTestHelpers: 0, |
Bryan Chan | 2de28dd | 2016-03-03 16:40:57 -0500 | [diff] [blame] | 584 | env: []string{"GOROOT_BOOTSTRAP=/var/buildlet/go-linux-s390x-bootstrap"}, |
Brad Fitzpatrick | c2a36fd | 2016-03-01 04:49:24 +0000 | [diff] [blame] | 585 | }) |
| 586 | |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 587 | } |
| 588 | |
| 589 | func addBuilder(c BuildConfig) { |
Brad Fitzpatrick | 1b6633d | 2016-01-27 07:24:57 +0000 | [diff] [blame] | 590 | if c.KubeImage != "" { |
| 591 | return // Disabled for now. https://golang.org/issue/14112 |
| 592 | } |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 593 | if c.Name == "" { |
| 594 | panic("empty name") |
| 595 | } |
| 596 | if _, dup := Builders[c.Name]; dup { |
| 597 | panic("dup name") |
| 598 | } |
Brad Fitzpatrick | 3cd1723 | 2015-10-01 22:07:22 +0000 | [diff] [blame] | 599 | if (c.VMImage == "" && c.KubeImage == "") && !c.IsReverse { |
| 600 | panic("empty VMImage and KubeImage on non-reverse builder") |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 601 | } |
Brad Fitzpatrick | 6925ce8 | 2015-09-08 15:18:47 -0700 | [diff] [blame] | 602 | if c.VMImage != "" && c.KubeImage != "" { |
| 603 | panic("there can be only one of VMImage/KubeImage") |
| 604 | } |
Brad Fitzpatrick | 46cc759 | 2015-01-15 12:46:22 -0800 | [diff] [blame] | 605 | Builders[c.Name] = c |
| 606 | } |