1. Packages
  2. Google Cloud Native
  3. API Docs
  4. cloudbuild
  5. cloudbuild/v1beta1
  6. WorkerPool

Google Cloud Native is in preview. Google Cloud Classic is fully supported.

Google Cloud Native v0.32.0 published on Wednesday, Nov 29, 2023 by Pulumi

google-native.cloudbuild/v1beta1.WorkerPool

Explore with Pulumi AI

Google Cloud Native is in preview. Google Cloud Classic is fully supported.

Google Cloud Native v0.32.0 published on Wednesday, Nov 29, 2023 by Pulumi

Creates a WorkerPool to run the builds, and returns the new worker pool. NOTE: As of now, this method returns an Operation that is always complete. Auto-naming is currently not supported for this resource.

Create WorkerPool Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new WorkerPool(name: string, args: WorkerPoolArgs, opts?: CustomResourceOptions);
@overload
def WorkerPool(resource_name: str,
               args: WorkerPoolArgs,
               opts: Optional[ResourceOptions] = None)

@overload
def WorkerPool(resource_name: str,
               opts: Optional[ResourceOptions] = None,
               worker_pool_id: Optional[str] = None,
               annotations: Optional[Mapping[str, str]] = None,
               display_name: Optional[str] = None,
               location: Optional[str] = None,
               network_config: Optional[NetworkConfigArgs] = None,
               project: Optional[str] = None,
               worker_config: Optional[WorkerConfigArgs] = None)
func NewWorkerPool(ctx *Context, name string, args WorkerPoolArgs, opts ...ResourceOption) (*WorkerPool, error)
public WorkerPool(string name, WorkerPoolArgs args, CustomResourceOptions? opts = null)
public WorkerPool(String name, WorkerPoolArgs args)
public WorkerPool(String name, WorkerPoolArgs args, CustomResourceOptions options)
type: google-native:cloudbuild/v1beta1:WorkerPool
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. WorkerPoolArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. WorkerPoolArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. WorkerPoolArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. WorkerPoolArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. WorkerPoolArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var exampleworkerPoolResourceResourceFromCloudbuildv1beta1 = new GoogleNative.CloudBuild.V1Beta1.WorkerPool("exampleworkerPoolResourceResourceFromCloudbuildv1beta1", new()
{
    WorkerPoolId = "string",
    Annotations = 
    {
        { "string", "string" },
    },
    DisplayName = "string",
    Location = "string",
    NetworkConfig = new GoogleNative.CloudBuild.V1Beta1.Inputs.NetworkConfigArgs
    {
        PeeredNetwork = "string",
    },
    Project = "string",
    WorkerConfig = new GoogleNative.CloudBuild.V1Beta1.Inputs.WorkerConfigArgs
    {
        DiskSizeGb = "string",
        MachineType = "string",
        NoExternalIp = false,
    },
});
Copy
example, err := cloudbuildv1beta1.NewWorkerPool(ctx, "exampleworkerPoolResourceResourceFromCloudbuildv1beta1", &cloudbuildv1beta1.WorkerPoolArgs{
	WorkerPoolId: pulumi.String("string"),
	Annotations: pulumi.StringMap{
		"string": pulumi.String("string"),
	},
	DisplayName: pulumi.String("string"),
	Location:    pulumi.String("string"),
	NetworkConfig: &cloudbuild.NetworkConfigArgs{
		PeeredNetwork: pulumi.String("string"),
	},
	Project: pulumi.String("string"),
	WorkerConfig: &cloudbuild.WorkerConfigArgs{
		DiskSizeGb:   pulumi.String("string"),
		MachineType:  pulumi.String("string"),
		NoExternalIp: pulumi.Bool(false),
	},
})
Copy
var exampleworkerPoolResourceResourceFromCloudbuildv1beta1 = new WorkerPool("exampleworkerPoolResourceResourceFromCloudbuildv1beta1", WorkerPoolArgs.builder()
    .workerPoolId("string")
    .annotations(Map.of("string", "string"))
    .displayName("string")
    .location("string")
    .networkConfig(NetworkConfigArgs.builder()
        .peeredNetwork("string")
        .build())
    .project("string")
    .workerConfig(WorkerConfigArgs.builder()
        .diskSizeGb("string")
        .machineType("string")
        .noExternalIp(false)
        .build())
    .build());
Copy
exampleworker_pool_resource_resource_from_cloudbuildv1beta1 = google_native.cloudbuild.v1beta1.WorkerPool("exampleworkerPoolResourceResourceFromCloudbuildv1beta1",
    worker_pool_id="string",
    annotations={
        "string": "string",
    },
    display_name="string",
    location="string",
    network_config={
        "peered_network": "string",
    },
    project="string",
    worker_config={
        "disk_size_gb": "string",
        "machine_type": "string",
        "no_external_ip": False,
    })
Copy
const exampleworkerPoolResourceResourceFromCloudbuildv1beta1 = new google_native.cloudbuild.v1beta1.WorkerPool("exampleworkerPoolResourceResourceFromCloudbuildv1beta1", {
    workerPoolId: "string",
    annotations: {
        string: "string",
    },
    displayName: "string",
    location: "string",
    networkConfig: {
        peeredNetwork: "string",
    },
    project: "string",
    workerConfig: {
        diskSizeGb: "string",
        machineType: "string",
        noExternalIp: false,
    },
});
Copy
type: google-native:cloudbuild/v1beta1:WorkerPool
properties:
    annotations:
        string: string
    displayName: string
    location: string
    networkConfig:
        peeredNetwork: string
    project: string
    workerConfig:
        diskSizeGb: string
        machineType: string
        noExternalIp: false
    workerPoolId: string
Copy

WorkerPool Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The WorkerPool resource accepts the following input properties:

WorkerPoolId
This property is required.
Changes to this property will trigger replacement.
string
Required. Immutable. The ID to use for the WorkerPool, which will become the final component of the resource name. This value should be 1-63 characters, and valid characters are /a-z-/.
Annotations Dictionary<string, string>
User specified annotations. See https://google.aip.dev/128#annotations for more details such as format and size limitations.
DisplayName string
A user-specified, human-readable name for the WorkerPool. If provided, this value must be 1-63 characters.
Location Changes to this property will trigger replacement. string
NetworkConfig Pulumi.GoogleNative.CloudBuild.V1Beta1.Inputs.NetworkConfig
Network configuration for the WorkerPool.
Project Changes to this property will trigger replacement. string
WorkerConfig Pulumi.GoogleNative.CloudBuild.V1Beta1.Inputs.WorkerConfig
Worker configuration for the WorkerPool.
WorkerPoolId
This property is required.
Changes to this property will trigger replacement.
string
Required. Immutable. The ID to use for the WorkerPool, which will become the final component of the resource name. This value should be 1-63 characters, and valid characters are /a-z-/.
Annotations map[string]string
User specified annotations. See https://google.aip.dev/128#annotations for more details such as format and size limitations.
DisplayName string
A user-specified, human-readable name for the WorkerPool. If provided, this value must be 1-63 characters.
Location Changes to this property will trigger replacement. string
NetworkConfig NetworkConfigArgs
Network configuration for the WorkerPool.
Project Changes to this property will trigger replacement. string
WorkerConfig WorkerConfigArgs
Worker configuration for the WorkerPool.
workerPoolId
This property is required.
Changes to this property will trigger replacement.
String
Required. Immutable. The ID to use for the WorkerPool, which will become the final component of the resource name. This value should be 1-63 characters, and valid characters are /a-z-/.
annotations Map<String,String>
User specified annotations. See https://google.aip.dev/128#annotations for more details such as format and size limitations.
displayName String
A user-specified, human-readable name for the WorkerPool. If provided, this value must be 1-63 characters.
location Changes to this property will trigger replacement. String
networkConfig NetworkConfig
Network configuration for the WorkerPool.
project Changes to this property will trigger replacement. String
workerConfig WorkerConfig
Worker configuration for the WorkerPool.
workerPoolId
This property is required.
Changes to this property will trigger replacement.
string
Required. Immutable. The ID to use for the WorkerPool, which will become the final component of the resource name. This value should be 1-63 characters, and valid characters are /a-z-/.
annotations {[key: string]: string}
User specified annotations. See https://google.aip.dev/128#annotations for more details such as format and size limitations.
displayName string
A user-specified, human-readable name for the WorkerPool. If provided, this value must be 1-63 characters.
location Changes to this property will trigger replacement. string
networkConfig NetworkConfig
Network configuration for the WorkerPool.
project Changes to this property will trigger replacement. string
workerConfig WorkerConfig
Worker configuration for the WorkerPool.
worker_pool_id
This property is required.
Changes to this property will trigger replacement.
str
Required. Immutable. The ID to use for the WorkerPool, which will become the final component of the resource name. This value should be 1-63 characters, and valid characters are /a-z-/.
annotations Mapping[str, str]
User specified annotations. See https://google.aip.dev/128#annotations for more details such as format and size limitations.
display_name str
A user-specified, human-readable name for the WorkerPool. If provided, this value must be 1-63 characters.
location Changes to this property will trigger replacement. str
network_config NetworkConfigArgs
Network configuration for the WorkerPool.
project Changes to this property will trigger replacement. str
worker_config WorkerConfigArgs
Worker configuration for the WorkerPool.
workerPoolId
This property is required.
Changes to this property will trigger replacement.
String
Required. Immutable. The ID to use for the WorkerPool, which will become the final component of the resource name. This value should be 1-63 characters, and valid characters are /a-z-/.
annotations Map<String>
User specified annotations. See https://google.aip.dev/128#annotations for more details such as format and size limitations.
displayName String
A user-specified, human-readable name for the WorkerPool. If provided, this value must be 1-63 characters.
location Changes to this property will trigger replacement. String
networkConfig Property Map
Network configuration for the WorkerPool.
project Changes to this property will trigger replacement. String
workerConfig Property Map
Worker configuration for the WorkerPool.

Outputs

All input properties are implicitly available as output properties. Additionally, the WorkerPool resource produces the following output properties:

CreateTime string
Time at which the request to create the WorkerPool was received.
DeleteTime string
Time at which the request to delete the WorkerPool was received.
Etag string
Checksum computed by the server. May be sent on update and delete requests to ensure that the client has an up-to-date value before proceeding.
Id string
The provider-assigned unique ID for this managed resource.
Name string
The resource name of the WorkerPool, with format projects/{project}/locations/{location}/workerPools/{worker_pool}. The value of {worker_pool} is provided by worker_pool_id in CreateWorkerPool request and the value of {location} is determined by the endpoint accessed.
State string
WorkerPool state.
Uid string
A unique identifier for the WorkerPool.
UpdateTime string
Time at which the request to update the WorkerPool was received.
CreateTime string
Time at which the request to create the WorkerPool was received.
DeleteTime string
Time at which the request to delete the WorkerPool was received.
Etag string
Checksum computed by the server. May be sent on update and delete requests to ensure that the client has an up-to-date value before proceeding.
Id string
The provider-assigned unique ID for this managed resource.
Name string
The resource name of the WorkerPool, with format projects/{project}/locations/{location}/workerPools/{worker_pool}. The value of {worker_pool} is provided by worker_pool_id in CreateWorkerPool request and the value of {location} is determined by the endpoint accessed.
State string
WorkerPool state.
Uid string
A unique identifier for the WorkerPool.
UpdateTime string
Time at which the request to update the WorkerPool was received.
createTime String
Time at which the request to create the WorkerPool was received.
deleteTime String
Time at which the request to delete the WorkerPool was received.
etag String
Checksum computed by the server. May be sent on update and delete requests to ensure that the client has an up-to-date value before proceeding.
id String
The provider-assigned unique ID for this managed resource.
name String
The resource name of the WorkerPool, with format projects/{project}/locations/{location}/workerPools/{worker_pool}. The value of {worker_pool} is provided by worker_pool_id in CreateWorkerPool request and the value of {location} is determined by the endpoint accessed.
state String
WorkerPool state.
uid String
A unique identifier for the WorkerPool.
updateTime String
Time at which the request to update the WorkerPool was received.
createTime string
Time at which the request to create the WorkerPool was received.
deleteTime string
Time at which the request to delete the WorkerPool was received.
etag string
Checksum computed by the server. May be sent on update and delete requests to ensure that the client has an up-to-date value before proceeding.
id string
The provider-assigned unique ID for this managed resource.
name string
The resource name of the WorkerPool, with format projects/{project}/locations/{location}/workerPools/{worker_pool}. The value of {worker_pool} is provided by worker_pool_id in CreateWorkerPool request and the value of {location} is determined by the endpoint accessed.
state string
WorkerPool state.
uid string
A unique identifier for the WorkerPool.
updateTime string
Time at which the request to update the WorkerPool was received.
create_time str
Time at which the request to create the WorkerPool was received.
delete_time str
Time at which the request to delete the WorkerPool was received.
etag str
Checksum computed by the server. May be sent on update and delete requests to ensure that the client has an up-to-date value before proceeding.
id str
The provider-assigned unique ID for this managed resource.
name str
The resource name of the WorkerPool, with format projects/{project}/locations/{location}/workerPools/{worker_pool}. The value of {worker_pool} is provided by worker_pool_id in CreateWorkerPool request and the value of {location} is determined by the endpoint accessed.
state str
WorkerPool state.
uid str
A unique identifier for the WorkerPool.
update_time str
Time at which the request to update the WorkerPool was received.
createTime String
Time at which the request to create the WorkerPool was received.
deleteTime String
Time at which the request to delete the WorkerPool was received.
etag String
Checksum computed by the server. May be sent on update and delete requests to ensure that the client has an up-to-date value before proceeding.
id String
The provider-assigned unique ID for this managed resource.
name String
The resource name of the WorkerPool, with format projects/{project}/locations/{location}/workerPools/{worker_pool}. The value of {worker_pool} is provided by worker_pool_id in CreateWorkerPool request and the value of {location} is determined by the endpoint accessed.
state String
WorkerPool state.
uid String
A unique identifier for the WorkerPool.
updateTime String
Time at which the request to update the WorkerPool was received.

Supporting Types

NetworkConfig
, NetworkConfigArgs

PeeredNetwork This property is required. string
Immutable. The network definition that the workers are peered to. If this section is left empty, the workers will be peered to WorkerPool.project_id on the service producer network. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number, such as 12345, and {network} is the name of a VPC network in the project. See Understanding network configuration options
PeeredNetwork This property is required. string
Immutable. The network definition that the workers are peered to. If this section is left empty, the workers will be peered to WorkerPool.project_id on the service producer network. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number, such as 12345, and {network} is the name of a VPC network in the project. See Understanding network configuration options
peeredNetwork This property is required. String
Immutable. The network definition that the workers are peered to. If this section is left empty, the workers will be peered to WorkerPool.project_id on the service producer network. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number, such as 12345, and {network} is the name of a VPC network in the project. See Understanding network configuration options
peeredNetwork This property is required. string
Immutable. The network definition that the workers are peered to. If this section is left empty, the workers will be peered to WorkerPool.project_id on the service producer network. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number, such as 12345, and {network} is the name of a VPC network in the project. See Understanding network configuration options
peered_network This property is required. str
Immutable. The network definition that the workers are peered to. If this section is left empty, the workers will be peered to WorkerPool.project_id on the service producer network. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number, such as 12345, and {network} is the name of a VPC network in the project. See Understanding network configuration options
peeredNetwork This property is required. String
Immutable. The network definition that the workers are peered to. If this section is left empty, the workers will be peered to WorkerPool.project_id on the service producer network. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number, such as 12345, and {network} is the name of a VPC network in the project. See Understanding network configuration options

NetworkConfigResponse
, NetworkConfigResponseArgs

PeeredNetwork This property is required. string
Immutable. The network definition that the workers are peered to. If this section is left empty, the workers will be peered to WorkerPool.project_id on the service producer network. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number, such as 12345, and {network} is the name of a VPC network in the project. See Understanding network configuration options
PeeredNetwork This property is required. string
Immutable. The network definition that the workers are peered to. If this section is left empty, the workers will be peered to WorkerPool.project_id on the service producer network. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number, such as 12345, and {network} is the name of a VPC network in the project. See Understanding network configuration options
peeredNetwork This property is required. String
Immutable. The network definition that the workers are peered to. If this section is left empty, the workers will be peered to WorkerPool.project_id on the service producer network. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number, such as 12345, and {network} is the name of a VPC network in the project. See Understanding network configuration options
peeredNetwork This property is required. string
Immutable. The network definition that the workers are peered to. If this section is left empty, the workers will be peered to WorkerPool.project_id on the service producer network. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number, such as 12345, and {network} is the name of a VPC network in the project. See Understanding network configuration options
peered_network This property is required. str
Immutable. The network definition that the workers are peered to. If this section is left empty, the workers will be peered to WorkerPool.project_id on the service producer network. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number, such as 12345, and {network} is the name of a VPC network in the project. See Understanding network configuration options
peeredNetwork This property is required. String
Immutable. The network definition that the workers are peered to. If this section is left empty, the workers will be peered to WorkerPool.project_id on the service producer network. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number, such as 12345, and {network} is the name of a VPC network in the project. See Understanding network configuration options

WorkerConfig
, WorkerConfigArgs

DiskSizeGb string
Size of the disk attached to the worker, in GB. See Worker pool config file. Specify a value of up to 1000. If 0 is specified, Cloud Build will use a standard disk size.
MachineType string
Machine type of a worker, such as n1-standard-1. See Worker pool config file. If left blank, Cloud Build will use n1-standard-1.
NoExternalIp bool
If true, workers are created without any public address, which prevents network egress to public IPs.
DiskSizeGb string
Size of the disk attached to the worker, in GB. See Worker pool config file. Specify a value of up to 1000. If 0 is specified, Cloud Build will use a standard disk size.
MachineType string
Machine type of a worker, such as n1-standard-1. See Worker pool config file. If left blank, Cloud Build will use n1-standard-1.
NoExternalIp bool
If true, workers are created without any public address, which prevents network egress to public IPs.
diskSizeGb String
Size of the disk attached to the worker, in GB. See Worker pool config file. Specify a value of up to 1000. If 0 is specified, Cloud Build will use a standard disk size.
machineType String
Machine type of a worker, such as n1-standard-1. See Worker pool config file. If left blank, Cloud Build will use n1-standard-1.
noExternalIp Boolean
If true, workers are created without any public address, which prevents network egress to public IPs.
diskSizeGb string
Size of the disk attached to the worker, in GB. See Worker pool config file. Specify a value of up to 1000. If 0 is specified, Cloud Build will use a standard disk size.
machineType string
Machine type of a worker, such as n1-standard-1. See Worker pool config file. If left blank, Cloud Build will use n1-standard-1.
noExternalIp boolean
If true, workers are created without any public address, which prevents network egress to public IPs.
disk_size_gb str
Size of the disk attached to the worker, in GB. See Worker pool config file. Specify a value of up to 1000. If 0 is specified, Cloud Build will use a standard disk size.
machine_type str
Machine type of a worker, such as n1-standard-1. See Worker pool config file. If left blank, Cloud Build will use n1-standard-1.
no_external_ip bool
If true, workers are created without any public address, which prevents network egress to public IPs.
diskSizeGb String
Size of the disk attached to the worker, in GB. See Worker pool config file. Specify a value of up to 1000. If 0 is specified, Cloud Build will use a standard disk size.
machineType String
Machine type of a worker, such as n1-standard-1. See Worker pool config file. If left blank, Cloud Build will use n1-standard-1.
noExternalIp Boolean
If true, workers are created without any public address, which prevents network egress to public IPs.

WorkerConfigResponse
, WorkerConfigResponseArgs

DiskSizeGb This property is required. string
Size of the disk attached to the worker, in GB. See Worker pool config file. Specify a value of up to 1000. If 0 is specified, Cloud Build will use a standard disk size.
MachineType This property is required. string
Machine type of a worker, such as n1-standard-1. See Worker pool config file. If left blank, Cloud Build will use n1-standard-1.
NoExternalIp This property is required. bool
If true, workers are created without any public address, which prevents network egress to public IPs.
DiskSizeGb This property is required. string
Size of the disk attached to the worker, in GB. See Worker pool config file. Specify a value of up to 1000. If 0 is specified, Cloud Build will use a standard disk size.
MachineType This property is required. string
Machine type of a worker, such as n1-standard-1. See Worker pool config file. If left blank, Cloud Build will use n1-standard-1.
NoExternalIp This property is required. bool
If true, workers are created without any public address, which prevents network egress to public IPs.
diskSizeGb This property is required. String
Size of the disk attached to the worker, in GB. See Worker pool config file. Specify a value of up to 1000. If 0 is specified, Cloud Build will use a standard disk size.
machineType This property is required. String
Machine type of a worker, such as n1-standard-1. See Worker pool config file. If left blank, Cloud Build will use n1-standard-1.
noExternalIp This property is required. Boolean
If true, workers are created without any public address, which prevents network egress to public IPs.
diskSizeGb This property is required. string
Size of the disk attached to the worker, in GB. See Worker pool config file. Specify a value of up to 1000. If 0 is specified, Cloud Build will use a standard disk size.
machineType This property is required. string
Machine type of a worker, such as n1-standard-1. See Worker pool config file. If left blank, Cloud Build will use n1-standard-1.
noExternalIp This property is required. boolean
If true, workers are created without any public address, which prevents network egress to public IPs.
disk_size_gb This property is required. str
Size of the disk attached to the worker, in GB. See Worker pool config file. Specify a value of up to 1000. If 0 is specified, Cloud Build will use a standard disk size.
machine_type This property is required. str
Machine type of a worker, such as n1-standard-1. See Worker pool config file. If left blank, Cloud Build will use n1-standard-1.
no_external_ip This property is required. bool
If true, workers are created without any public address, which prevents network egress to public IPs.
diskSizeGb This property is required. String
Size of the disk attached to the worker, in GB. See Worker pool config file. Specify a value of up to 1000. If 0 is specified, Cloud Build will use a standard disk size.
machineType This property is required. String
Machine type of a worker, such as n1-standard-1. See Worker pool config file. If left blank, Cloud Build will use n1-standard-1.
noExternalIp This property is required. Boolean
If true, workers are created without any public address, which prevents network egress to public IPs.

Package Details

Repository
Google Cloud Native pulumi/pulumi-google-native
License
Apache-2.0

Google Cloud Native is in preview. Google Cloud Classic is fully supported.

Google Cloud Native v0.32.0 published on Wednesday, Nov 29, 2023 by Pulumi