Build: A build resource in the Container Builder API.

At a high level, a Build describes where to find source code, how to build it (for example, the builder image to run on the source), and what tag to apply to the built image when it is pushed to Google Container Registry.

Build is referenced in 1 repository


// Fields can include the following variables which will be expanded
// when the
// build is created:
// - $PROJECT_ID: the project ID of the build.
// - $BUILD_ID: the autogenerated ID of the build.
// - $REPO_NAME: the source repository name specified by RepoSource.
// - $BRANCH_NAME: the branch name specified by RepoSource.
// - $TAG_NAME: the tag name specified by RepoSource.
// - $REVISION_ID or $COMMIT_SHA: the commit SHA specified by RepoSource
// or
//   resolved from the specified branch or tag.
type Build struct {
	// CreateTime: Time at which the build was created.
	// @OutputOnly
	CreateTime string `json:"createTime,omitempty"`

	// FinishTime: Time at which execution of the build was
	// finished.
	// @OutputOnly
	FinishTime string `json:"finishTime,omitempty"`

	// Id: Unique identifier of the build.
	// @OutputOnly
	Id string `json:"id,omitempty"`

	// Images: A list of images to be pushed upon the successful completion
	// of all build
	// steps.
	// The images will be pushed using the builder
	// service account's credentials.
	// The digests of the pushed images will be stored in the Build
	// resource's
	// results field.
	// If any of the images fail to be pushed, the build is marked FAILURE.
	Images []string `json:"images,omitempty"`

	// LogUrl: URL to logs for this build in Google Cloud
	// Logging.
	// @OutputOnly
	LogUrl string `json:"logUrl,omitempty"`

	// LogsBucket: Google Cloud Storage bucket where logs should be written
	// (see
	// [Bucket
	// Name
	// Requirements](
	// #requirements)).
	// Logs file names will be of the format
	// `${logs_bucket}/log-${build_id}.txt`.
	LogsBucket string `json:"logsBucket,omitempty"`

	// Options: Special options for this build.
	Options *BuildOptions `json:"options,omitempty"`

	// ProjectId: ID of the project.
	// @OutputOnly.
	ProjectId string `json:"projectId,omitempty"`

	// Results: Results of the build.
	// @OutputOnly
	Results *Results `json:"results,omitempty"`

	// Source: Describes where to find the source files to build.
	Source *Source `json:"source,omitempty"`

	// SourceProvenance: A permanent fixed identifier for
	// source.
	// @OutputOnly
	SourceProvenance *SourceProvenance `json:"sourceProvenance,omitempty"`

	// StartTime: Time at which execution of the build was
	// started.
	// @OutputOnly
	StartTime string `json:"startTime,omitempty"`

	// Status: Status of the build.
	// @OutputOnly
	// Possible values:
	//   "STATUS_UNKNOWN" - Status of the build is unknown.
	//   "QUEUING" - Build has been received and is being queued.
	//   "QUEUED" - Build is queued; work has not yet begun.
	//   "WORKING" - Build is being executed.
	//   "SUCCESS" - Build finished successfully.
	//   "FAILURE" - Build failed to complete successfully.
	//   "INTERNAL_ERROR" - Build failed due to an internal cause.
	//   "TIMEOUT" - Build took longer than was allowed.
	//   "CANCELLED" - Build was canceled by a user.
	Status string `json:"status,omitempty"`

	// StatusDetail: Customer-readable message about the current
	// status.
	// @OutputOnly
	StatusDetail string `json:"statusDetail,omitempty"`

	// Steps: Describes the operations to be performed on the workspace.
	Steps []*BuildStep `json:"steps,omitempty"`

	// Timeout: Amount of time that this build should be allowed to run, to
	// second
	// granularity. If this amount of time elapses, work on the build will