-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
dashboard/app: add a JSON output mode for the data on the front page
Fixes golang/go#9493 Change-Id: I4891abf530901c620c2923e9f2d3e3227dd7ced9 Reviewed-on: https://go-review.googlesource.com/2290 Reviewed-by: Andrew Gerrand <[email protected]>
- Loading branch information
Showing
3 changed files
with
121 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,35 +2,29 @@ | |
// Use of this source code is governed by a BSD-style | ||
// license that can be found in the LICENSE file. | ||
|
||
The files in this directory constitute the continuous builder: | ||
The files in these directories constitute the continuous builder: | ||
|
||
app/: an AppEngine server. The code that runs http://build.golang.org/ | ||
app/: a.k.a the "dashboard"; the App Engine code that runs http://build.golang.org/ | ||
buildlet/: HTTP server that runs on a VM and is told what to write to disk | ||
and what command to run. This is cross-compiled to all architectures | ||
and what command to run. This is cross-compiled to different architectures | ||
and is the first program run when a builder VM comes up. It then | ||
is contacted by the coordinator to do a build. | ||
builder/: gobuilder, a Go continuous build client | ||
is contacted by the coordinator to do a build. Not all builders use | ||
the buildlet (at least not yet). | ||
builder/: gobuilder, a Go continuous build client. The original Go builder program. | ||
coordinator/: daemon that runs on CoreOS on Google Compute Engine and manages | ||
builds (using the builder in single-shot mode) in Docker containers. | ||
env/: configuration files describing the environment of builders and related binaries. | ||
Many builders are still configured ad-hoc. | ||
builds using Docker containers and/or VMs as needed. | ||
env/: configuration files describing the environment of builders and related | ||
binaries. Many builders are still configured ad-hoc, without a hermetic | ||
environment. | ||
retrybuilds/: a Go client program to delete build results from the dashboard (app) | ||
types/: a Go package contain common types used by other pieces. | ||
watcher/: a daemon that watches for new commits to the Go repository and | ||
its sub-repositories, and notifies the dashboard of those commits. | ||
|
||
If you wish to run a Go builder, please email [email protected] | ||
If you wish to run a Go builder, please email [email protected] first. | ||
There is documentation at https://golang.org/wiki/DashboardBuilders but | ||
depending on the type of builder, we may want to run it ourselves, after you | ||
prepare an environment description (resulting in a VM image) of it. See the env | ||
directory. | ||
|
||
To run a builder: | ||
|
||
* Write the key ~gobuild/.gobuildkey | ||
You need to get it from someone who knows the key. | ||
You may also use a filename of the form .gobuildkey-$BUILDER if you | ||
wish to run builders for multiple targets. | ||
|
||
* Append your username and password googlecode.com credentials from | ||
https://code.google.com/hosting/settings | ||
to the buildkey file in the format "Username\nPassword\n". | ||
(This is for uploading tarballs to the project downloads section, | ||
and is an optional step.) | ||
|
||
* Build and run gobuilder (see its documentation for command-line options). | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
// Copyright 2011 The Go Authors. All rights reserved. | ||
// Use of this source code is governed by a BSD-style | ||
// license that can be found in the LICENSE file. | ||
|
||
// Package types contains common types used by the Go continuous build | ||
// system. | ||
package types | ||
|
||
// BuildStatus is the data structure that's marshalled as JSON | ||
// for the http://build.golang.org/?mode=json page. | ||
type BuildStatus struct { | ||
// Builders is a list of all known builders. | ||
// The order that builders appear is the same order as the build results for a revision. | ||
Builders []string `json:"builders"` | ||
|
||
// Revisions are the revisions shown on the front page of build.golang.org, | ||
// in the same order. It starts with the "go" repo, from recent to old, and then | ||
// it has 1 each of the subrepos, with only their most recent commit. | ||
Revisions []BuildRevision `json:"revisions"` | ||
} | ||
|
||
// BuildRevision is the status of a commit across all builders. | ||
// It corresponds to a single row of http://build.golang.org/ | ||
type BuildRevision struct { | ||
// Repo is "go" for the main repo, else "tools", "crypto", "net", etc. | ||
// These are repos as listed at https://go.googlesource.com/ | ||
Repo string `json:"repo"` | ||
|
||
// Revision is the full git hash of the repo. | ||
Revision string `json:"revision"` | ||
|
||
// GoRevision is the full git hash of the "go" repo, if Repo is not "go" itself. | ||
// Otherwise this is empty. | ||
GoRevision string `json:"goRevision,omitempty"` | ||
|
||
// Results are the build results for each of the builders in | ||
// the same length slice BuildStatus.Builders. | ||
// Each string is either "" (if no data), "ok", or the URL to failure logs. | ||
Results []string `json:"results"` | ||
} |