Class ComputeInstance.Builder
- java.lang.Object
-
- com.hashicorp.cdktf.providers.google.compute_instance.ComputeInstance.Builder
-
- All Implemented Interfaces:
software.amazon.jsii.Builder<ComputeInstance>
- Enclosing class:
- ComputeInstance
@Stability(Stable) public static final class ComputeInstance.Builder extends Object implements software.amazon.jsii.Builder<ComputeInstance>
A fluent builder forComputeInstance.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ComputeInstance.BuilderadvancedMachineFeatures(ComputeInstanceAdvancedMachineFeatures advancedMachineFeatures)advanced_machine_features block.ComputeInstance.BuilderallowStoppingForUpdate(com.hashicorp.cdktf.IResolvable allowStoppingForUpdate)If true, allows Terraform to stop the instance to update its properties.ComputeInstance.BuilderallowStoppingForUpdate(Boolean allowStoppingForUpdate)If true, allows Terraform to stop the instance to update its properties.ComputeInstance.BuilderattachedDisk(com.hashicorp.cdktf.IResolvable attachedDisk)attached_disk block.ComputeInstance.BuilderattachedDisk(List<? extends ComputeInstanceAttachedDisk> attachedDisk)attached_disk block.ComputeInstance.BuilderbootDisk(ComputeInstanceBootDisk bootDisk)boot_disk block.ComputeInstancebuild()ComputeInstance.BuildercanIpForward(com.hashicorp.cdktf.IResolvable canIpForward)Whether sending and receiving of packets with non-matching source or destination IPs is allowed.ComputeInstance.BuildercanIpForward(Boolean canIpForward)Whether sending and receiving of packets with non-matching source or destination IPs is allowed.ComputeInstance.BuilderconfidentialInstanceConfig(ComputeInstanceConfidentialInstanceConfig confidentialInstanceConfig)confidential_instance_config block.ComputeInstance.Builderconnection(com.hashicorp.cdktf.SSHProvisionerConnection connection)ComputeInstance.Builderconnection(com.hashicorp.cdktf.WinrmProvisionerConnection connection)ComputeInstance.Buildercount(com.hashicorp.cdktf.TerraformCount count)ComputeInstance.Buildercount(Number count)static ComputeInstance.Buildercreate(software.constructs.Construct scope, String id)ComputeInstance.BuilderdeletionProtection(com.hashicorp.cdktf.IResolvable deletionProtection)Whether deletion protection is enabled on this instance.ComputeInstance.BuilderdeletionProtection(Boolean deletionProtection)Whether deletion protection is enabled on this instance.ComputeInstance.BuilderdependsOn(List<? extends com.hashicorp.cdktf.ITerraformDependable> dependsOn)ComputeInstance.Builderdescription(String description)A brief description of the resource.ComputeInstance.BuilderdesiredStatus(String desiredStatus)Desired status of the instance.ComputeInstance.BuilderenableDisplay(com.hashicorp.cdktf.IResolvable enableDisplay)Whether the instance has virtual displays enabled.ComputeInstance.BuilderenableDisplay(Boolean enableDisplay)Whether the instance has virtual displays enabled.ComputeInstance.BuilderforEach(com.hashicorp.cdktf.ITerraformIterator forEach)ComputeInstance.BuilderguestAccelerator(com.hashicorp.cdktf.IResolvable guestAccelerator)List of the type and count of accelerator cards attached to the instance.ComputeInstance.BuilderguestAccelerator(List<? extends ComputeInstanceGuestAccelerator> guestAccelerator)List of the type and count of accelerator cards attached to the instance.ComputeInstance.Builderhostname(String hostname)A custom hostname for the instance.ComputeInstance.Builderid(String id)Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#id ComputeInstance#id}.ComputeInstance.Builderlabels(Map<String,String> labels)A set of key/value label pairs assigned to the instance.ComputeInstance.Builderlifecycle(com.hashicorp.cdktf.TerraformResourceLifecycle lifecycle)ComputeInstance.BuildermachineType(String machineType)The machine type to create.ComputeInstance.Buildermetadata(Map<String,String> metadata)Metadata key/value pairs made available within the instance.ComputeInstance.BuildermetadataStartupScript(String metadataStartupScript)Metadata startup scripts made available within the instance.ComputeInstance.BuilderminCpuPlatform(String minCpuPlatform)The minimum CPU platform specified for the VM instance.ComputeInstance.Buildername(String name)The name of the instance.ComputeInstance.BuildernetworkInterface(com.hashicorp.cdktf.IResolvable networkInterface)network_interface block.ComputeInstance.BuildernetworkInterface(List<? extends ComputeInstanceNetworkInterface> networkInterface)network_interface block.ComputeInstance.BuildernetworkPerformanceConfig(ComputeInstanceNetworkPerformanceConfig networkPerformanceConfig)network_performance_config block.ComputeInstance.Builderparams(ComputeInstanceParams params)params block.ComputeInstance.Builderproject(String project)The ID of the project in which the resource belongs.ComputeInstance.Builderprovider(com.hashicorp.cdktf.TerraformProvider provider)ComputeInstance.Builderprovisioners(List<? extends Object> provisioners)ComputeInstance.BuilderreservationAffinity(ComputeInstanceReservationAffinity reservationAffinity)reservation_affinity block.ComputeInstance.BuilderresourcePolicies(List<String> resourcePolicies)A list of self_links of resource policies to attach to the instance.ComputeInstance.Builderscheduling(ComputeInstanceScheduling scheduling)scheduling block.ComputeInstance.BuilderscratchDisk(com.hashicorp.cdktf.IResolvable scratchDisk)scratch_disk block.ComputeInstance.BuilderscratchDisk(List<? extends ComputeInstanceScratchDisk> scratchDisk)scratch_disk block.ComputeInstance.BuilderserviceAccount(ComputeInstanceServiceAccount serviceAccount)service_account block.ComputeInstance.BuildershieldedInstanceConfig(ComputeInstanceShieldedInstanceConfig shieldedInstanceConfig)shielded_instance_config block.ComputeInstance.Buildertags(List<String> tags)The list of tags attached to the instance.ComputeInstance.Buildertimeouts(ComputeInstanceTimeouts timeouts)timeouts block.ComputeInstance.Builderzone(String zone)The zone of the instance.
-
-
-
Method Detail
-
create
@Stability(Stable) public static ComputeInstance.Builder create(software.constructs.Construct scope, String id)
- Parameters:
scope- The scope in which to define this construct. This parameter is required.id- The scoped construct ID. This parameter is required.- Returns:
- a new instance of
ComputeInstance.Builder.
-
connection
@Stability(Experimental) public ComputeInstance.Builder connection(com.hashicorp.cdktf.SSHProvisionerConnection connection)
- Parameters:
connection- This parameter is required.- Returns:
this
-
connection
@Stability(Experimental) public ComputeInstance.Builder connection(com.hashicorp.cdktf.WinrmProvisionerConnection connection)
- Parameters:
connection- This parameter is required.- Returns:
this
-
count
@Stability(Experimental) public ComputeInstance.Builder count(Number count)
- Parameters:
count- This parameter is required.- Returns:
this
-
count
@Stability(Experimental) public ComputeInstance.Builder count(com.hashicorp.cdktf.TerraformCount count)
- Parameters:
count- This parameter is required.- Returns:
this
-
dependsOn
@Stability(Experimental) public ComputeInstance.Builder dependsOn(List<? extends com.hashicorp.cdktf.ITerraformDependable> dependsOn)
- Parameters:
dependsOn- This parameter is required.- Returns:
this
-
forEach
@Stability(Experimental) public ComputeInstance.Builder forEach(com.hashicorp.cdktf.ITerraformIterator forEach)
- Parameters:
forEach- This parameter is required.- Returns:
this
-
lifecycle
@Stability(Experimental) public ComputeInstance.Builder lifecycle(com.hashicorp.cdktf.TerraformResourceLifecycle lifecycle)
- Parameters:
lifecycle- This parameter is required.- Returns:
this
-
provider
@Stability(Experimental) public ComputeInstance.Builder provider(com.hashicorp.cdktf.TerraformProvider provider)
- Parameters:
provider- This parameter is required.- Returns:
this
-
provisioners
@Stability(Experimental) public ComputeInstance.Builder provisioners(List<? extends Object> provisioners)
- Parameters:
provisioners- This parameter is required.- Returns:
this
-
bootDisk
@Stability(Stable) public ComputeInstance.Builder bootDisk(ComputeInstanceBootDisk bootDisk)
boot_disk block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#boot_disk ComputeInstance#boot_disk}
- Parameters:
bootDisk- boot_disk block. This parameter is required.- Returns:
this
-
machineType
@Stability(Stable) public ComputeInstance.Builder machineType(String machineType)
The machine type to create.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#machine_type ComputeInstance#machine_type}
- Parameters:
machineType- The machine type to create. This parameter is required.- Returns:
this
-
name
@Stability(Stable) public ComputeInstance.Builder name(String name)
The name of the instance. One of name or self_link must be provided.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#name ComputeInstance#name}
- Parameters:
name- The name of the instance. One of name or self_link must be provided. This parameter is required.- Returns:
this
-
networkInterface
@Stability(Stable) public ComputeInstance.Builder networkInterface(com.hashicorp.cdktf.IResolvable networkInterface)
network_interface block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#network_interface ComputeInstance#network_interface}
- Parameters:
networkInterface- network_interface block. This parameter is required.- Returns:
this
-
networkInterface
@Stability(Stable) public ComputeInstance.Builder networkInterface(List<? extends ComputeInstanceNetworkInterface> networkInterface)
network_interface block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#network_interface ComputeInstance#network_interface}
- Parameters:
networkInterface- network_interface block. This parameter is required.- Returns:
this
-
advancedMachineFeatures
@Stability(Stable) public ComputeInstance.Builder advancedMachineFeatures(ComputeInstanceAdvancedMachineFeatures advancedMachineFeatures)
advanced_machine_features block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#advanced_machine_features ComputeInstance#advanced_machine_features}
- Parameters:
advancedMachineFeatures- advanced_machine_features block. This parameter is required.- Returns:
this
-
allowStoppingForUpdate
@Stability(Stable) public ComputeInstance.Builder allowStoppingForUpdate(Boolean allowStoppingForUpdate)
If true, allows Terraform to stop the instance to update its properties.If you try to update a property that requires stopping the instance without setting this field, the update will fail. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#allow_stopping_for_update ComputeInstance#allow_stopping_for_update}
- Parameters:
allowStoppingForUpdate- If true, allows Terraform to stop the instance to update its properties. This parameter is required.- Returns:
this
-
allowStoppingForUpdate
@Stability(Stable) public ComputeInstance.Builder allowStoppingForUpdate(com.hashicorp.cdktf.IResolvable allowStoppingForUpdate)
If true, allows Terraform to stop the instance to update its properties.If you try to update a property that requires stopping the instance without setting this field, the update will fail. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#allow_stopping_for_update ComputeInstance#allow_stopping_for_update}
- Parameters:
allowStoppingForUpdate- If true, allows Terraform to stop the instance to update its properties. This parameter is required.- Returns:
this
-
attachedDisk
@Stability(Stable) public ComputeInstance.Builder attachedDisk(com.hashicorp.cdktf.IResolvable attachedDisk)
attached_disk block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#attached_disk ComputeInstance#attached_disk}
- Parameters:
attachedDisk- attached_disk block. This parameter is required.- Returns:
this
-
attachedDisk
@Stability(Stable) public ComputeInstance.Builder attachedDisk(List<? extends ComputeInstanceAttachedDisk> attachedDisk)
attached_disk block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#attached_disk ComputeInstance#attached_disk}
- Parameters:
attachedDisk- attached_disk block. This parameter is required.- Returns:
this
-
canIpForward
@Stability(Stable) public ComputeInstance.Builder canIpForward(Boolean canIpForward)
Whether sending and receiving of packets with non-matching source or destination IPs is allowed.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#can_ip_forward ComputeInstance#can_ip_forward}
- Parameters:
canIpForward- Whether sending and receiving of packets with non-matching source or destination IPs is allowed. This parameter is required.- Returns:
this
-
canIpForward
@Stability(Stable) public ComputeInstance.Builder canIpForward(com.hashicorp.cdktf.IResolvable canIpForward)
Whether sending and receiving of packets with non-matching source or destination IPs is allowed.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#can_ip_forward ComputeInstance#can_ip_forward}
- Parameters:
canIpForward- Whether sending and receiving of packets with non-matching source or destination IPs is allowed. This parameter is required.- Returns:
this
-
confidentialInstanceConfig
@Stability(Stable) public ComputeInstance.Builder confidentialInstanceConfig(ComputeInstanceConfidentialInstanceConfig confidentialInstanceConfig)
confidential_instance_config block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#confidential_instance_config ComputeInstance#confidential_instance_config}
- Parameters:
confidentialInstanceConfig- confidential_instance_config block. This parameter is required.- Returns:
this
-
deletionProtection
@Stability(Stable) public ComputeInstance.Builder deletionProtection(Boolean deletionProtection)
Whether deletion protection is enabled on this instance.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#deletion_protection ComputeInstance#deletion_protection}
- Parameters:
deletionProtection- Whether deletion protection is enabled on this instance. This parameter is required.- Returns:
this
-
deletionProtection
@Stability(Stable) public ComputeInstance.Builder deletionProtection(com.hashicorp.cdktf.IResolvable deletionProtection)
Whether deletion protection is enabled on this instance.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#deletion_protection ComputeInstance#deletion_protection}
- Parameters:
deletionProtection- Whether deletion protection is enabled on this instance. This parameter is required.- Returns:
this
-
description
@Stability(Stable) public ComputeInstance.Builder description(String description)
A brief description of the resource.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#description ComputeInstance#description}
- Parameters:
description- A brief description of the resource. This parameter is required.- Returns:
this
-
desiredStatus
@Stability(Stable) public ComputeInstance.Builder desiredStatus(String desiredStatus)
Desired status of the instance. Either "RUNNING" or "TERMINATED".Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#desired_status ComputeInstance#desired_status}
- Parameters:
desiredStatus- Desired status of the instance. Either "RUNNING" or "TERMINATED". This parameter is required.- Returns:
this
-
enableDisplay
@Stability(Stable) public ComputeInstance.Builder enableDisplay(Boolean enableDisplay)
Whether the instance has virtual displays enabled.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#enable_display ComputeInstance#enable_display}
- Parameters:
enableDisplay- Whether the instance has virtual displays enabled. This parameter is required.- Returns:
this
-
enableDisplay
@Stability(Stable) public ComputeInstance.Builder enableDisplay(com.hashicorp.cdktf.IResolvable enableDisplay)
Whether the instance has virtual displays enabled.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#enable_display ComputeInstance#enable_display}
- Parameters:
enableDisplay- Whether the instance has virtual displays enabled. This parameter is required.- Returns:
this
-
guestAccelerator
@Stability(Stable) public ComputeInstance.Builder guestAccelerator(com.hashicorp.cdktf.IResolvable guestAccelerator)
List of the type and count of accelerator cards attached to the instance.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#guest_accelerator ComputeInstance#guest_accelerator}
- Parameters:
guestAccelerator- List of the type and count of accelerator cards attached to the instance. This parameter is required.- Returns:
this
-
guestAccelerator
@Stability(Stable) public ComputeInstance.Builder guestAccelerator(List<? extends ComputeInstanceGuestAccelerator> guestAccelerator)
List of the type and count of accelerator cards attached to the instance.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#guest_accelerator ComputeInstance#guest_accelerator}
- Parameters:
guestAccelerator- List of the type and count of accelerator cards attached to the instance. This parameter is required.- Returns:
this
-
hostname
@Stability(Stable) public ComputeInstance.Builder hostname(String hostname)
A custom hostname for the instance.Must be a fully qualified DNS name and RFC-1035-valid. Valid format is a series of labels 1-63 characters long matching the regular expression [a-z](%5B-a-z0-9%5D*%5Ba-z0-9%5D), concatenated with periods. The entire hostname must not exceed 253 characters. Changing this forces a new resource to be created. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#hostname ComputeInstance#hostname}
- Parameters:
hostname- A custom hostname for the instance. This parameter is required.- Returns:
this
-
id
@Stability(Stable) public ComputeInstance.Builder id(String id)
Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#id ComputeInstance#id}.Please be aware that the id field is automatically added to all resources in Terraform providers using a Terraform provider SDK version below 2. If you experience problems setting this value it might not be settable. Please take a look at the provider documentation to ensure it should be settable.
- Parameters:
id- Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#id ComputeInstance#id}. This parameter is required.- Returns:
this
-
labels
@Stability(Stable) public ComputeInstance.Builder labels(Map<String,String> labels)
A set of key/value label pairs assigned to the instance.**Note**: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field 'effective_labels' for all of the labels present on the resource. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#labels ComputeInstance#labels}
- Parameters:
labels- A set of key/value label pairs assigned to the instance. This parameter is required.- Returns:
this
-
metadata
@Stability(Stable) public ComputeInstance.Builder metadata(Map<String,String> metadata)
Metadata key/value pairs made available within the instance.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#metadata ComputeInstance#metadata}
- Parameters:
metadata- Metadata key/value pairs made available within the instance. This parameter is required.- Returns:
this
-
metadataStartupScript
@Stability(Stable) public ComputeInstance.Builder metadataStartupScript(String metadataStartupScript)
Metadata startup scripts made available within the instance.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#metadata_startup_script ComputeInstance#metadata_startup_script}
- Parameters:
metadataStartupScript- Metadata startup scripts made available within the instance. This parameter is required.- Returns:
this
-
minCpuPlatform
@Stability(Stable) public ComputeInstance.Builder minCpuPlatform(String minCpuPlatform)
The minimum CPU platform specified for the VM instance.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#min_cpu_platform ComputeInstance#min_cpu_platform}
- Parameters:
minCpuPlatform- The minimum CPU platform specified for the VM instance. This parameter is required.- Returns:
this
-
networkPerformanceConfig
@Stability(Stable) public ComputeInstance.Builder networkPerformanceConfig(ComputeInstanceNetworkPerformanceConfig networkPerformanceConfig)
network_performance_config block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#network_performance_config ComputeInstance#network_performance_config}
- Parameters:
networkPerformanceConfig- network_performance_config block. This parameter is required.- Returns:
this
-
params
@Stability(Stable) public ComputeInstance.Builder params(ComputeInstanceParams params)
params block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#params ComputeInstance#params}
- Parameters:
params- params block. This parameter is required.- Returns:
this
-
project
@Stability(Stable) public ComputeInstance.Builder project(String project)
The ID of the project in which the resource belongs.If self_link is provided, this value is ignored. If neither self_link nor project are provided, the provider project is used. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#project ComputeInstance#project}
- Parameters:
project- The ID of the project in which the resource belongs. This parameter is required.- Returns:
this
-
reservationAffinity
@Stability(Stable) public ComputeInstance.Builder reservationAffinity(ComputeInstanceReservationAffinity reservationAffinity)
reservation_affinity block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#reservation_affinity ComputeInstance#reservation_affinity}
- Parameters:
reservationAffinity- reservation_affinity block. This parameter is required.- Returns:
this
-
resourcePolicies
@Stability(Stable) public ComputeInstance.Builder resourcePolicies(List<String> resourcePolicies)
A list of self_links of resource policies to attach to the instance.Currently a max of 1 resource policy is supported. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#resource_policies ComputeInstance#resource_policies}
- Parameters:
resourcePolicies- A list of self_links of resource policies to attach to the instance. This parameter is required.- Returns:
this
-
scheduling
@Stability(Stable) public ComputeInstance.Builder scheduling(ComputeInstanceScheduling scheduling)
scheduling block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#scheduling ComputeInstance#scheduling}
- Parameters:
scheduling- scheduling block. This parameter is required.- Returns:
this
-
scratchDisk
@Stability(Stable) public ComputeInstance.Builder scratchDisk(com.hashicorp.cdktf.IResolvable scratchDisk)
scratch_disk block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#scratch_disk ComputeInstance#scratch_disk}
- Parameters:
scratchDisk- scratch_disk block. This parameter is required.- Returns:
this
-
scratchDisk
@Stability(Stable) public ComputeInstance.Builder scratchDisk(List<? extends ComputeInstanceScratchDisk> scratchDisk)
scratch_disk block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#scratch_disk ComputeInstance#scratch_disk}
- Parameters:
scratchDisk- scratch_disk block. This parameter is required.- Returns:
this
-
serviceAccount
@Stability(Stable) public ComputeInstance.Builder serviceAccount(ComputeInstanceServiceAccount serviceAccount)
service_account block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#service_account ComputeInstance#service_account}
- Parameters:
serviceAccount- service_account block. This parameter is required.- Returns:
this
-
shieldedInstanceConfig
@Stability(Stable) public ComputeInstance.Builder shieldedInstanceConfig(ComputeInstanceShieldedInstanceConfig shieldedInstanceConfig)
shielded_instance_config block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#shielded_instance_config ComputeInstance#shielded_instance_config}
- Parameters:
shieldedInstanceConfig- shielded_instance_config block. This parameter is required.- Returns:
this
-
tags
@Stability(Stable) public ComputeInstance.Builder tags(List<String> tags)
The list of tags attached to the instance.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#tags ComputeInstance#tags}
- Parameters:
tags- The list of tags attached to the instance. This parameter is required.- Returns:
this
-
timeouts
@Stability(Stable) public ComputeInstance.Builder timeouts(ComputeInstanceTimeouts timeouts)
timeouts block.Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#timeouts ComputeInstance#timeouts}
- Parameters:
timeouts- timeouts block. This parameter is required.- Returns:
this
-
zone
@Stability(Stable) public ComputeInstance.Builder zone(String zone)
The zone of the instance.If self_link is provided, this value is ignored. If neither self_link nor zone are provided, the provider zone is used. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_instance#zone ComputeInstance#zone}
- Parameters:
zone- The zone of the instance. This parameter is required.- Returns:
this
-
build
@Stability(Stable) public ComputeInstance build()
- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<ComputeInstance>- Returns:
- a newly built instance of
ComputeInstance.
-
-