Class BuildOptions (1.1.0)

public sealed class BuildOptions : IMessage<BuildOptions>, IEquatable<BuildOptions>, IDeepCloneable<BuildOptions>, IBufferMessage, IMessage

Optional arguments to enable specific features of builds.

Inheritance

Object > BuildOptions

Namespace

Google.Cloud.CloudBuild.V1

Assembly

Google.Cloud.CloudBuild.V1.dll

Constructors

BuildOptions()

public BuildOptions()

BuildOptions(BuildOptions)

public BuildOptions(BuildOptions other)
Parameter
NameDescription
otherBuildOptions

Properties

DiskSizeGb

public long DiskSizeGb { get; set; }

Requested disk size for the VM that runs the build. Note that this is NOT "disk free"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 1000GB; builds that request more than the maximum are rejected with an error.

Property Value
TypeDescription
Int64

DynamicSubstitutions

public bool DynamicSubstitutions { get; set; }

Option to specify whether or not to apply bash style string operations to the substitutions.

NOTE: this is always enabled for triggered builds and cannot be overridden in the build configuration file.

Property Value
TypeDescription
Boolean

Env

public RepeatedField<string> Env { get; }

A list of global environment variable definitions that will exist for all build steps in this build. If a variable is defined in both globally and in a build step, the variable will use the build step value.

The elements are of the form "KEY=VALUE" for the environment variable "KEY" being given the value "VALUE".

Property Value
TypeDescription
RepeatedField<String>

Logging

public BuildOptions.Types.LoggingMode Logging { get; set; }

Option to specify the logging mode, which determines if and where build logs are stored.

Property Value
TypeDescription
BuildOptions.Types.LoggingMode

LogStreamingOption

public BuildOptions.Types.LogStreamingOption LogStreamingOption { get; set; }

Option to define build log streaming behavior to Google Cloud Storage.

Property Value
TypeDescription
BuildOptions.Types.LogStreamingOption

MachineType

public BuildOptions.Types.MachineType MachineType { get; set; }

Compute Engine machine type on which to run the build.

Property Value
TypeDescription
BuildOptions.Types.MachineType

RequestedVerifyOption

public BuildOptions.Types.VerifyOption RequestedVerifyOption { get; set; }

Requested verifiability options.

Property Value
TypeDescription
BuildOptions.Types.VerifyOption

SecretEnv

public RepeatedField<string> SecretEnv { get; }

A list of global environment variables, which are encrypted using a Cloud Key Management Service crypto key. These values must be specified in the build's Secret. These variables will be available to all build steps in this build.

Property Value
TypeDescription
RepeatedField<String>

SourceProvenanceHash

public RepeatedField<Hash.Types.HashType> SourceProvenanceHash { get; }

Requested hash for SourceProvenance.

Property Value
TypeDescription
RepeatedField<Hash.Types.HashType>

SubstitutionOption

public BuildOptions.Types.SubstitutionOption SubstitutionOption { get; set; }

Option to specify behavior when there is an error in the substitution checks.

NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot be overridden in the build configuration file.

Property Value
TypeDescription
BuildOptions.Types.SubstitutionOption

Volumes

public RepeatedField<Volume> Volumes { get; }

Global list of volumes to mount for ALL build steps

Each volume is created as an empty volume prior to starting the build process. Upon completion of the build, volumes and their contents are discarded. Global volume names and paths cannot conflict with the volumes defined a build step.

Using a global volume in a build with only one step is not valid as it is indicative of a build request with an incorrect configuration.

Property Value
TypeDescription
RepeatedField<Volume>

WorkerPool

public string WorkerPool { get; set; }

Option to specify a WorkerPool for the build. Format: projects/{project}/locations/{location}/workerPools/{workerPool}

This field is experimental.

Property Value
TypeDescription
String