Class ComputeRouterPeerConfig.Builder
- java.lang.Object
-
- com.hashicorp.cdktf.providers.google.compute_router_peer.ComputeRouterPeerConfig.Builder
-
- All Implemented Interfaces:
software.amazon.jsii.Builder<ComputeRouterPeerConfig>
- Enclosing interface:
- ComputeRouterPeerConfig
@Stability(Stable) public static final class ComputeRouterPeerConfig.Builder extends Object implements software.amazon.jsii.Builder<ComputeRouterPeerConfig>
A builder forComputeRouterPeerConfig
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
-
-
-
Method Detail
-
interfaceValue
@Stability(Stable) public ComputeRouterPeerConfig.Builder interfaceValue(String interfaceValue)
Sets the value ofComputeRouterPeerConfig.getInterfaceValue()- Parameters:
interfaceValue- Name of the interface the BGP peer is associated with. This parameter is required. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#interface ComputeRouterPeer#interface}- Returns:
this
-
name
@Stability(Stable) public ComputeRouterPeerConfig.Builder name(String name)
Sets the value ofComputeRouterPeerConfig.getName()- Parameters:
name- Name of this BGP peer. This parameter is required. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression '[a-z](%5B-a-z0-9%5D*%5Ba-z0-9%5D)?' which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#name ComputeRouterPeer#name}- Returns:
this
-
peerAsn
@Stability(Stable) public ComputeRouterPeerConfig.Builder peerAsn(Number peerAsn)
Sets the value ofComputeRouterPeerConfig.getPeerAsn()- Parameters:
peerAsn- Peer BGP Autonomous System Number (ASN). Each BGP interface may use a different value. This parameter is required. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#peer_asn ComputeRouterPeer#peer_asn}- Returns:
this
-
router
@Stability(Stable) public ComputeRouterPeerConfig.Builder router(String router)
Sets the value ofComputeRouterPeerConfig.getRouter()- Parameters:
router- The name of the Cloud Router in which this BgpPeer will be configured. This parameter is required. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#router ComputeRouterPeer#router}- Returns:
this
-
advertisedGroups
@Stability(Stable) public ComputeRouterPeerConfig.Builder advertisedGroups(List<String> advertisedGroups)
Sets the value ofComputeRouterPeerConfig.getAdvertisedGroups()- Parameters:
advertisedGroups- User-specified list of prefix groups to advertise in custom mode, which currently supports the following option:. * 'ALL_SUBNETS': Advertises all of the router's own VPC subnets. This excludes any routes learned for subnets that use VPC Network Peering. Note that this field can only be populated if advertiseMode is 'CUSTOM' and overrides the list defined for the router (in the "bgp" message). These groups are advertised in addition to any specified prefixes. Leave this field blank to advertise no custom groups. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#advertised_groups ComputeRouterPeer#advertised_groups}- Returns:
this
-
advertisedIpRanges
@Stability(Stable) public ComputeRouterPeerConfig.Builder advertisedIpRanges(com.hashicorp.cdktf.IResolvable advertisedIpRanges)
Sets the value ofComputeRouterPeerConfig.getAdvertisedIpRanges()- Parameters:
advertisedIpRanges- advertised_ip_ranges block. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#advertised_ip_ranges ComputeRouterPeer#advertised_ip_ranges}- Returns:
this
-
advertisedIpRanges
@Stability(Stable) public ComputeRouterPeerConfig.Builder advertisedIpRanges(List<? extends ComputeRouterPeerAdvertisedIpRanges> advertisedIpRanges)
Sets the value ofComputeRouterPeerConfig.getAdvertisedIpRanges()- Parameters:
advertisedIpRanges- advertised_ip_ranges block. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#advertised_ip_ranges ComputeRouterPeer#advertised_ip_ranges}- Returns:
this
-
advertisedRoutePriority
@Stability(Stable) public ComputeRouterPeerConfig.Builder advertisedRoutePriority(Number advertisedRoutePriority)
Sets the value ofComputeRouterPeerConfig.getAdvertisedRoutePriority()- Parameters:
advertisedRoutePriority- The priority of routes advertised to this BGP peer. Where there is more than one matching route of maximum length, the routes with the lowest priority value win. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#advertised_route_priority ComputeRouterPeer#advertised_route_priority}- Returns:
this
-
advertiseMode
@Stability(Stable) public ComputeRouterPeerConfig.Builder advertiseMode(String advertiseMode)
Sets the value ofComputeRouterPeerConfig.getAdvertiseMode()- Parameters:
advertiseMode- User-specified flag to indicate which mode to use for advertisement. Valid values of this enum field are: 'DEFAULT', 'CUSTOM' Default value: "DEFAULT" Possible values: ["DEFAULT", "CUSTOM"] Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#advertise_mode ComputeRouterPeer#advertise_mode}- Returns:
this
-
bfd
@Stability(Stable) public ComputeRouterPeerConfig.Builder bfd(ComputeRouterPeerBfd bfd)
Sets the value ofComputeRouterPeerConfig.getBfd()- Parameters:
bfd- bfd block. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#bfd ComputeRouterPeer#bfd}- Returns:
this
-
customLearnedIpRanges
@Stability(Stable) public ComputeRouterPeerConfig.Builder customLearnedIpRanges(com.hashicorp.cdktf.IResolvable customLearnedIpRanges)
Sets the value ofComputeRouterPeerConfig.getCustomLearnedIpRanges()- Parameters:
customLearnedIpRanges- custom_learned_ip_ranges block. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#custom_learned_ip_ranges ComputeRouterPeer#custom_learned_ip_ranges}- Returns:
this
-
customLearnedIpRanges
@Stability(Stable) public ComputeRouterPeerConfig.Builder customLearnedIpRanges(List<? extends ComputeRouterPeerCustomLearnedIpRanges> customLearnedIpRanges)
Sets the value ofComputeRouterPeerConfig.getCustomLearnedIpRanges()- Parameters:
customLearnedIpRanges- custom_learned_ip_ranges block. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#custom_learned_ip_ranges ComputeRouterPeer#custom_learned_ip_ranges}- Returns:
this
-
customLearnedRoutePriority
@Stability(Stable) public ComputeRouterPeerConfig.Builder customLearnedRoutePriority(Number customLearnedRoutePriority)
Sets the value ofComputeRouterPeerConfig.getCustomLearnedRoutePriority()- Parameters:
customLearnedRoutePriority- The user-defined custom learned route priority for a BGP session. This value is applied to all custom learned route ranges for the session. You can choose a value from 0 to 65335. If you don't provide a value, Google Cloud assigns a priority of 100 to the ranges. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#custom_learned_route_priority ComputeRouterPeer#custom_learned_route_priority}- Returns:
this
-
enable
@Stability(Stable) public ComputeRouterPeerConfig.Builder enable(Boolean enable)
Sets the value ofComputeRouterPeerConfig.getEnable()- Parameters:
enable- The status of the BGP peer connection. If set to false, any active session with the peer is terminated and all associated routing information is removed. If set to true, the peer connection can be established with routing information. The default is true. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#enable ComputeRouterPeer#enable}- Returns:
this
-
enable
@Stability(Stable) public ComputeRouterPeerConfig.Builder enable(com.hashicorp.cdktf.IResolvable enable)
Sets the value ofComputeRouterPeerConfig.getEnable()- Parameters:
enable- The status of the BGP peer connection. If set to false, any active session with the peer is terminated and all associated routing information is removed. If set to true, the peer connection can be established with routing information. The default is true. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#enable ComputeRouterPeer#enable}- Returns:
this
-
enableIpv4
@Stability(Stable) public ComputeRouterPeerConfig.Builder enableIpv4(Boolean enableIpv4)
Sets the value ofComputeRouterPeerConfig.getEnableIpv4()- Parameters:
enableIpv4- Enable IPv4 traffic over BGP Peer. It is enabled by default if the peerIpAddress is version 4. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#enable_ipv4 ComputeRouterPeer#enable_ipv4}- Returns:
this
-
enableIpv4
@Stability(Stable) public ComputeRouterPeerConfig.Builder enableIpv4(com.hashicorp.cdktf.IResolvable enableIpv4)
Sets the value ofComputeRouterPeerConfig.getEnableIpv4()- Parameters:
enableIpv4- Enable IPv4 traffic over BGP Peer. It is enabled by default if the peerIpAddress is version 4. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#enable_ipv4 ComputeRouterPeer#enable_ipv4}- Returns:
this
-
enableIpv6
@Stability(Stable) public ComputeRouterPeerConfig.Builder enableIpv6(Boolean enableIpv6)
Sets the value ofComputeRouterPeerConfig.getEnableIpv6()- Parameters:
enableIpv6- Enable IPv6 traffic over BGP Peer. If not specified, it is disabled by default. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#enable_ipv6 ComputeRouterPeer#enable_ipv6}- Returns:
this
-
enableIpv6
@Stability(Stable) public ComputeRouterPeerConfig.Builder enableIpv6(com.hashicorp.cdktf.IResolvable enableIpv6)
Sets the value ofComputeRouterPeerConfig.getEnableIpv6()- Parameters:
enableIpv6- Enable IPv6 traffic over BGP Peer. If not specified, it is disabled by default. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#enable_ipv6 ComputeRouterPeer#enable_ipv6}- Returns:
this
-
id
@Stability(Stable) public ComputeRouterPeerConfig.Builder id(String id)
Sets the value ofComputeRouterPeerConfig.getId()- Parameters:
id- Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#id ComputeRouterPeer#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.- Returns:
this
-
ipAddress
@Stability(Stable) public ComputeRouterPeerConfig.Builder ipAddress(String ipAddress)
Sets the value ofComputeRouterPeerConfig.getIpAddress()- Parameters:
ipAddress- IP address of the interface inside Google Cloud Platform. Only IPv4 is supported. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#ip_address ComputeRouterPeer#ip_address}- Returns:
this
-
ipv4NexthopAddress
@Stability(Stable) public ComputeRouterPeerConfig.Builder ipv4NexthopAddress(String ipv4NexthopAddress)
Sets the value ofComputeRouterPeerConfig.getIpv4NexthopAddress()- Parameters:
ipv4NexthopAddress- IPv4 address of the interface inside Google Cloud Platform. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#ipv4_nexthop_address ComputeRouterPeer#ipv4_nexthop_address}- Returns:
this
-
ipv6NexthopAddress
@Stability(Stable) public ComputeRouterPeerConfig.Builder ipv6NexthopAddress(String ipv6NexthopAddress)
Sets the value ofComputeRouterPeerConfig.getIpv6NexthopAddress()- Parameters:
ipv6NexthopAddress- IPv6 address of the interface inside Google Cloud Platform. The address must be in the range 2600:2d00:0:2::/64 or 2600:2d00:0:3::/64. If you do not specify the next hop addresses, Google Cloud automatically assigns unused addresses from the 2600:2d00:0:2::/64 or 2600:2d00:0:3::/64 range for you. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#ipv6_nexthop_address ComputeRouterPeer#ipv6_nexthop_address}- Returns:
this
-
md5AuthenticationKey
@Stability(Stable) public ComputeRouterPeerConfig.Builder md5AuthenticationKey(ComputeRouterPeerMd5AuthenticationKey md5AuthenticationKey)
Sets the value ofComputeRouterPeerConfig.getMd5AuthenticationKey()- Parameters:
md5AuthenticationKey- md5_authentication_key block. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#md5_authentication_key ComputeRouterPeer#md5_authentication_key}- Returns:
this
-
peerIpAddress
@Stability(Stable) public ComputeRouterPeerConfig.Builder peerIpAddress(String peerIpAddress)
Sets the value ofComputeRouterPeerConfig.getPeerIpAddress()- Parameters:
peerIpAddress- IP address of the BGP interface outside Google Cloud Platform. Only IPv4 is supported. Required if 'ip_address' is set. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#peer_ip_address ComputeRouterPeer#peer_ip_address}- Returns:
this
-
peerIpv4NexthopAddress
@Stability(Stable) public ComputeRouterPeerConfig.Builder peerIpv4NexthopAddress(String peerIpv4NexthopAddress)
Sets the value ofComputeRouterPeerConfig.getPeerIpv4NexthopAddress()- Parameters:
peerIpv4NexthopAddress- IPv4 address of the BGP interface outside Google Cloud Platform. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#peer_ipv4_nexthop_address ComputeRouterPeer#peer_ipv4_nexthop_address}- Returns:
this
-
peerIpv6NexthopAddress
@Stability(Stable) public ComputeRouterPeerConfig.Builder peerIpv6NexthopAddress(String peerIpv6NexthopAddress)
Sets the value ofComputeRouterPeerConfig.getPeerIpv6NexthopAddress()- Parameters:
peerIpv6NexthopAddress- IPv6 address of the BGP interface outside Google Cloud Platform. The address must be in the range 2600:2d00:0:2::/64 or 2600:2d00:0:3::/64. If you do not specify the next hop addresses, Google Cloud automatically assigns unused addresses from the 2600:2d00:0:2::/64 or 2600:2d00:0:3::/64 range for you. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#peer_ipv6_nexthop_address ComputeRouterPeer#peer_ipv6_nexthop_address}- Returns:
this
-
project
@Stability(Stable) public ComputeRouterPeerConfig.Builder project(String project)
Sets the value ofComputeRouterPeerConfig.getProject()- Parameters:
project- Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#project ComputeRouterPeer#project}.- Returns:
this
-
region
@Stability(Stable) public ComputeRouterPeerConfig.Builder region(String region)
Sets the value ofComputeRouterPeerConfig.getRegion()- Parameters:
region- Region where the router and BgpPeer reside. If it is not provided, the provider region is used. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#region ComputeRouterPeer#region}- Returns:
this
-
routerApplianceInstance
@Stability(Stable) public ComputeRouterPeerConfig.Builder routerApplianceInstance(String routerApplianceInstance)
Sets the value ofComputeRouterPeerConfig.getRouterApplianceInstance()- Parameters:
routerApplianceInstance- The URI of the VM instance that is used as third-party router appliances such as Next Gen Firewalls, Virtual Routers, or Router Appliances. The VM instance must be located in zones contained in the same region as this Cloud Router. The VM instance is the peer side of the BGP session. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#router_appliance_instance ComputeRouterPeer#router_appliance_instance}- Returns:
this
-
timeouts
@Stability(Stable) public ComputeRouterPeerConfig.Builder timeouts(ComputeRouterPeerTimeouts timeouts)
Sets the value ofComputeRouterPeerConfig.getTimeouts()- Parameters:
timeouts- timeouts block. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/compute_router_peer#timeouts ComputeRouterPeer#timeouts}- Returns:
this
-
connection
@Stability(Experimental) public ComputeRouterPeerConfig.Builder connection(com.hashicorp.cdktf.SSHProvisionerConnection connection)
Sets the value ofTerraformMetaArguments.getConnection()- Parameters:
connection- the value to be set.- Returns:
this
-
connection
@Stability(Experimental) public ComputeRouterPeerConfig.Builder connection(com.hashicorp.cdktf.WinrmProvisionerConnection connection)
Sets the value ofTerraformMetaArguments.getConnection()- Parameters:
connection- the value to be set.- Returns:
this
-
count
@Stability(Experimental) public ComputeRouterPeerConfig.Builder count(Number count)
Sets the value ofTerraformMetaArguments.getCount()- Parameters:
count- the value to be set.- Returns:
this
-
count
@Stability(Experimental) public ComputeRouterPeerConfig.Builder count(com.hashicorp.cdktf.TerraformCount count)
Sets the value ofTerraformMetaArguments.getCount()- Parameters:
count- the value to be set.- Returns:
this
-
dependsOn
@Stability(Experimental) public ComputeRouterPeerConfig.Builder dependsOn(List<? extends com.hashicorp.cdktf.ITerraformDependable> dependsOn)
Sets the value ofTerraformMetaArguments.getDependsOn()- Parameters:
dependsOn- the value to be set.- Returns:
this
-
forEach
@Stability(Experimental) public ComputeRouterPeerConfig.Builder forEach(com.hashicorp.cdktf.ITerraformIterator forEach)
Sets the value ofTerraformMetaArguments.getForEach()- Parameters:
forEach- the value to be set.- Returns:
this
-
lifecycle
@Stability(Experimental) public ComputeRouterPeerConfig.Builder lifecycle(com.hashicorp.cdktf.TerraformResourceLifecycle lifecycle)
Sets the value ofTerraformMetaArguments.getLifecycle()- Parameters:
lifecycle- the value to be set.- Returns:
this
-
provider
@Stability(Experimental) public ComputeRouterPeerConfig.Builder provider(com.hashicorp.cdktf.TerraformProvider provider)
Sets the value ofTerraformMetaArguments.getProvider()- Parameters:
provider- the value to be set.- Returns:
this
-
provisioners
@Stability(Experimental) public ComputeRouterPeerConfig.Builder provisioners(List<? extends Object> provisioners)
Sets the value ofTerraformMetaArguments.getProvisioners()- Parameters:
provisioners- the value to be set.- Returns:
this
-
build
@Stability(Stable) public ComputeRouterPeerConfig build()
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<ComputeRouterPeerConfig>- Returns:
- a new instance of
ComputeRouterPeerConfig - Throws:
NullPointerException- if any required attribute was not provided
-
-