Google Cloud Native is in preview. Google Cloud Classic is fully supported.
google-native.compute/alpha.NetworkAttachment
Explore with Pulumi AI
Google Cloud Native is in preview. Google Cloud Classic is fully supported.
Creates a NetworkAttachment in the specified project in the given scope using the parameters that are included in the request.
Create NetworkAttachment Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new NetworkAttachment(name: string, args: NetworkAttachmentArgs, opts?: CustomResourceOptions);
@overload
def NetworkAttachment(resource_name: str,
args: NetworkAttachmentArgs,
opts: Optional[ResourceOptions] = None)
@overload
def NetworkAttachment(resource_name: str,
opts: Optional[ResourceOptions] = None,
region: Optional[str] = None,
connection_preference: Optional[NetworkAttachmentConnectionPreference] = None,
description: Optional[str] = None,
name: Optional[str] = None,
producer_accept_lists: Optional[Sequence[str]] = None,
producer_reject_lists: Optional[Sequence[str]] = None,
project: Optional[str] = None,
request_id: Optional[str] = None,
subnetworks: Optional[Sequence[str]] = None)
func NewNetworkAttachment(ctx *Context, name string, args NetworkAttachmentArgs, opts ...ResourceOption) (*NetworkAttachment, error)
public NetworkAttachment(string name, NetworkAttachmentArgs args, CustomResourceOptions? opts = null)
public NetworkAttachment(String name, NetworkAttachmentArgs args)
public NetworkAttachment(String name, NetworkAttachmentArgs args, CustomResourceOptions options)
type: google-native:compute/alpha:NetworkAttachment
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args NetworkAttachmentArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args NetworkAttachmentArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args NetworkAttachmentArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args NetworkAttachmentArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args NetworkAttachmentArgs
- 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 networkAttachmentResource = new GoogleNative.Compute.Alpha.NetworkAttachment("networkAttachmentResource", new()
{
Region = "string",
ConnectionPreference = GoogleNative.Compute.Alpha.NetworkAttachmentConnectionPreference.AcceptAutomatic,
Description = "string",
Name = "string",
ProducerAcceptLists = new[]
{
"string",
},
ProducerRejectLists = new[]
{
"string",
},
Project = "string",
RequestId = "string",
Subnetworks = new[]
{
"string",
},
});
example, err := compute.NewNetworkAttachment(ctx, "networkAttachmentResource", &compute.NetworkAttachmentArgs{
Region: pulumi.String("string"),
ConnectionPreference: compute.NetworkAttachmentConnectionPreferenceAcceptAutomatic,
Description: pulumi.String("string"),
Name: pulumi.String("string"),
ProducerAcceptLists: pulumi.StringArray{
pulumi.String("string"),
},
ProducerRejectLists: pulumi.StringArray{
pulumi.String("string"),
},
Project: pulumi.String("string"),
RequestId: pulumi.String("string"),
Subnetworks: pulumi.StringArray{
pulumi.String("string"),
},
})
var networkAttachmentResource = new NetworkAttachment("networkAttachmentResource", NetworkAttachmentArgs.builder()
.region("string")
.connectionPreference("ACCEPT_AUTOMATIC")
.description("string")
.name("string")
.producerAcceptLists("string")
.producerRejectLists("string")
.project("string")
.requestId("string")
.subnetworks("string")
.build());
network_attachment_resource = google_native.compute.alpha.NetworkAttachment("networkAttachmentResource",
region="string",
connection_preference=google_native.compute.alpha.NetworkAttachmentConnectionPreference.ACCEPT_AUTOMATIC,
description="string",
name="string",
producer_accept_lists=["string"],
producer_reject_lists=["string"],
project="string",
request_id="string",
subnetworks=["string"])
const networkAttachmentResource = new google_native.compute.alpha.NetworkAttachment("networkAttachmentResource", {
region: "string",
connectionPreference: google_native.compute.alpha.NetworkAttachmentConnectionPreference.AcceptAutomatic,
description: "string",
name: "string",
producerAcceptLists: ["string"],
producerRejectLists: ["string"],
project: "string",
requestId: "string",
subnetworks: ["string"],
});
type: google-native:compute/alpha:NetworkAttachment
properties:
connectionPreference: ACCEPT_AUTOMATIC
description: string
name: string
producerAcceptLists:
- string
producerRejectLists:
- string
project: string
region: string
requestId: string
subnetworks:
- string
NetworkAttachment 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 NetworkAttachment resource accepts the following input properties:
- Region string
- Connection
Preference Pulumi.Google Native. Compute. Alpha. Network Attachment Connection Preference - Description string
- An optional description of this resource. Provide this property when you create the resource.
- Name string
- Name of the resource. Provided by the client when the resource is created. 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]([-a-z0-9]*[a-z0-9])?
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. - Producer
Accept List<string>Lists - Projects that are allowed to connect to this network attachment. The project can be specified using its id or number.
- Producer
Reject List<string>Lists - Projects that are not allowed to connect to this network attachment. The project can be specified using its id or number.
- Project string
- Request
Id string - An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000). end_interface: MixerMutationRequestBuilder
- Subnetworks List<string>
- An array of URLs where each entry is the URL of a subnet provided by the service consumer to use for endpoints in the producers that connect to this network attachment.
- Region string
- Connection
Preference NetworkAttachment Connection Preference - Description string
- An optional description of this resource. Provide this property when you create the resource.
- Name string
- Name of the resource. Provided by the client when the resource is created. 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]([-a-z0-9]*[a-z0-9])?
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. - Producer
Accept []stringLists - Projects that are allowed to connect to this network attachment. The project can be specified using its id or number.
- Producer
Reject []stringLists - Projects that are not allowed to connect to this network attachment. The project can be specified using its id or number.
- Project string
- Request
Id string - An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000). end_interface: MixerMutationRequestBuilder
- Subnetworks []string
- An array of URLs where each entry is the URL of a subnet provided by the service consumer to use for endpoints in the producers that connect to this network attachment.
- region String
- connection
Preference NetworkAttachment Connection Preference - description String
- An optional description of this resource. Provide this property when you create the resource.
- name String
- Name of the resource. Provided by the client when the resource is created. 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]([-a-z0-9]*[a-z0-9])?
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. - producer
Accept List<String>Lists - Projects that are allowed to connect to this network attachment. The project can be specified using its id or number.
- producer
Reject List<String>Lists - Projects that are not allowed to connect to this network attachment. The project can be specified using its id or number.
- project String
- request
Id String - An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000). end_interface: MixerMutationRequestBuilder
- subnetworks List<String>
- An array of URLs where each entry is the URL of a subnet provided by the service consumer to use for endpoints in the producers that connect to this network attachment.
- region string
- connection
Preference NetworkAttachment Connection Preference - description string
- An optional description of this resource. Provide this property when you create the resource.
- name string
- Name of the resource. Provided by the client when the resource is created. 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]([-a-z0-9]*[a-z0-9])?
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. - producer
Accept string[]Lists - Projects that are allowed to connect to this network attachment. The project can be specified using its id or number.
- producer
Reject string[]Lists - Projects that are not allowed to connect to this network attachment. The project can be specified using its id or number.
- project string
- request
Id string - An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000). end_interface: MixerMutationRequestBuilder
- subnetworks string[]
- An array of URLs where each entry is the URL of a subnet provided by the service consumer to use for endpoints in the producers that connect to this network attachment.
- region str
- connection_
preference NetworkAttachment Connection Preference - description str
- An optional description of this resource. Provide this property when you create the resource.
- name str
- Name of the resource. Provided by the client when the resource is created. 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]([-a-z0-9]*[a-z0-9])?
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. - producer_
accept_ Sequence[str]lists - Projects that are allowed to connect to this network attachment. The project can be specified using its id or number.
- producer_
reject_ Sequence[str]lists - Projects that are not allowed to connect to this network attachment. The project can be specified using its id or number.
- project str
- request_
id str - An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000). end_interface: MixerMutationRequestBuilder
- subnetworks Sequence[str]
- An array of URLs where each entry is the URL of a subnet provided by the service consumer to use for endpoints in the producers that connect to this network attachment.
- region String
- connection
Preference "ACCEPT_AUTOMATIC" | "ACCEPT_MANUAL" | "INVALID" - description String
- An optional description of this resource. Provide this property when you create the resource.
- name String
- Name of the resource. Provided by the client when the resource is created. 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]([-a-z0-9]*[a-z0-9])?
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. - producer
Accept List<String>Lists - Projects that are allowed to connect to this network attachment. The project can be specified using its id or number.
- producer
Reject List<String>Lists - Projects that are not allowed to connect to this network attachment. The project can be specified using its id or number.
- project String
- request
Id String - An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000). end_interface: MixerMutationRequestBuilder
- subnetworks List<String>
- An array of URLs where each entry is the URL of a subnet provided by the service consumer to use for endpoints in the producers that connect to this network attachment.
Outputs
All input properties are implicitly available as output properties. Additionally, the NetworkAttachment resource produces the following output properties:
- Connection
Endpoints List<Pulumi.Google Native. Compute. Alpha. Outputs. Network Attachment Connected Endpoint Response> - An array of connections for all the producers connected to this network attachment.
- Creation
Timestamp string - Creation timestamp in RFC3339 text format.
- Fingerprint string
- Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. An up-to-date fingerprint must be provided in order to patch.
- Id string
- The provider-assigned unique ID for this managed resource.
- Kind string
- Type of the resource.
- Network string
- The URL of the network which the Network Attachment belongs to. Practically it is inferred by fetching the network of the first subnetwork associated. Because it is required that all the subnetworks must be from the same network, it is assured that the Network Attachment belongs to the same network as all the subnetworks.
- Self
Link string - Server-defined URL for the resource.
- Self
Link stringWith Id - Server-defined URL for this resource's resource id.
- Connection
Endpoints []NetworkAttachment Connected Endpoint Response - An array of connections for all the producers connected to this network attachment.
- Creation
Timestamp string - Creation timestamp in RFC3339 text format.
- Fingerprint string
- Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. An up-to-date fingerprint must be provided in order to patch.
- Id string
- The provider-assigned unique ID for this managed resource.
- Kind string
- Type of the resource.
- Network string
- The URL of the network which the Network Attachment belongs to. Practically it is inferred by fetching the network of the first subnetwork associated. Because it is required that all the subnetworks must be from the same network, it is assured that the Network Attachment belongs to the same network as all the subnetworks.
- Self
Link string - Server-defined URL for the resource.
- Self
Link stringWith Id - Server-defined URL for this resource's resource id.
- connection
Endpoints List<NetworkAttachment Connected Endpoint Response> - An array of connections for all the producers connected to this network attachment.
- creation
Timestamp String - Creation timestamp in RFC3339 text format.
- fingerprint String
- Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. An up-to-date fingerprint must be provided in order to patch.
- id String
- The provider-assigned unique ID for this managed resource.
- kind String
- Type of the resource.
- network String
- The URL of the network which the Network Attachment belongs to. Practically it is inferred by fetching the network of the first subnetwork associated. Because it is required that all the subnetworks must be from the same network, it is assured that the Network Attachment belongs to the same network as all the subnetworks.
- self
Link String - Server-defined URL for the resource.
- self
Link StringWith Id - Server-defined URL for this resource's resource id.
- connection
Endpoints NetworkAttachment Connected Endpoint Response[] - An array of connections for all the producers connected to this network attachment.
- creation
Timestamp string - Creation timestamp in RFC3339 text format.
- fingerprint string
- Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. An up-to-date fingerprint must be provided in order to patch.
- id string
- The provider-assigned unique ID for this managed resource.
- kind string
- Type of the resource.
- network string
- The URL of the network which the Network Attachment belongs to. Practically it is inferred by fetching the network of the first subnetwork associated. Because it is required that all the subnetworks must be from the same network, it is assured that the Network Attachment belongs to the same network as all the subnetworks.
- self
Link string - Server-defined URL for the resource.
- self
Link stringWith Id - Server-defined URL for this resource's resource id.
- connection_
endpoints Sequence[NetworkAttachment Connected Endpoint Response] - An array of connections for all the producers connected to this network attachment.
- creation_
timestamp str - Creation timestamp in RFC3339 text format.
- fingerprint str
- Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. An up-to-date fingerprint must be provided in order to patch.
- id str
- The provider-assigned unique ID for this managed resource.
- kind str
- Type of the resource.
- network str
- The URL of the network which the Network Attachment belongs to. Practically it is inferred by fetching the network of the first subnetwork associated. Because it is required that all the subnetworks must be from the same network, it is assured that the Network Attachment belongs to the same network as all the subnetworks.
- self_
link str - Server-defined URL for the resource.
- self_
link_ strwith_ id - Server-defined URL for this resource's resource id.
- connection
Endpoints List<Property Map> - An array of connections for all the producers connected to this network attachment.
- creation
Timestamp String - Creation timestamp in RFC3339 text format.
- fingerprint String
- Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. An up-to-date fingerprint must be provided in order to patch.
- id String
- The provider-assigned unique ID for this managed resource.
- kind String
- Type of the resource.
- network String
- The URL of the network which the Network Attachment belongs to. Practically it is inferred by fetching the network of the first subnetwork associated. Because it is required that all the subnetworks must be from the same network, it is assured that the Network Attachment belongs to the same network as all the subnetworks.
- self
Link String - Server-defined URL for the resource.
- self
Link StringWith Id - Server-defined URL for this resource's resource id.
Supporting Types
NetworkAttachmentConnectedEndpointResponse, NetworkAttachmentConnectedEndpointResponseArgs
- Ip
Address string - The IPv4 address assigned to the producer instance network interface. This value will be a range in case of Serverless.
- Ipv6Address string
- The IPv6 address assigned to the producer instance network interface. This is only assigned when the stack types of both the instance network interface and the consumer subnet are IPv4_IPv6.
- Project
Id stringOr Num - The project id or number of the interface to which the IP was assigned.
- Secondary
Ip List<string>Cidr Ranges - Alias IP ranges from the same subnetwork.
- Status string
- The status of a connected endpoint to this network attachment.
- Subnetwork string
- The subnetwork used to assign the IP to the producer instance network interface.
- Subnetwork
Cidr stringRange - The CIDR range of the subnet from which the IPv4 internal IP was allocated from.
- Ip
Address string - The IPv4 address assigned to the producer instance network interface. This value will be a range in case of Serverless.
- Ipv6Address string
- The IPv6 address assigned to the producer instance network interface. This is only assigned when the stack types of both the instance network interface and the consumer subnet are IPv4_IPv6.
- Project
Id stringOr Num - The project id or number of the interface to which the IP was assigned.
- Secondary
Ip []stringCidr Ranges - Alias IP ranges from the same subnetwork.
- Status string
- The status of a connected endpoint to this network attachment.
- Subnetwork string
- The subnetwork used to assign the IP to the producer instance network interface.
- Subnetwork
Cidr stringRange - The CIDR range of the subnet from which the IPv4 internal IP was allocated from.
- ip
Address String - The IPv4 address assigned to the producer instance network interface. This value will be a range in case of Serverless.
- ipv6Address String
- The IPv6 address assigned to the producer instance network interface. This is only assigned when the stack types of both the instance network interface and the consumer subnet are IPv4_IPv6.
- project
Id StringOr Num - The project id or number of the interface to which the IP was assigned.
- secondary
Ip List<String>Cidr Ranges - Alias IP ranges from the same subnetwork.
- status String
- The status of a connected endpoint to this network attachment.
- subnetwork String
- The subnetwork used to assign the IP to the producer instance network interface.
- subnetwork
Cidr StringRange - The CIDR range of the subnet from which the IPv4 internal IP was allocated from.
- ip
Address string - The IPv4 address assigned to the producer instance network interface. This value will be a range in case of Serverless.
- ipv6Address string
- The IPv6 address assigned to the producer instance network interface. This is only assigned when the stack types of both the instance network interface and the consumer subnet are IPv4_IPv6.
- project
Id stringOr Num - The project id or number of the interface to which the IP was assigned.
- secondary
Ip string[]Cidr Ranges - Alias IP ranges from the same subnetwork.
- status string
- The status of a connected endpoint to this network attachment.
- subnetwork string
- The subnetwork used to assign the IP to the producer instance network interface.
- subnetwork
Cidr stringRange - The CIDR range of the subnet from which the IPv4 internal IP was allocated from.
- ip_
address str - The IPv4 address assigned to the producer instance network interface. This value will be a range in case of Serverless.
- ipv6_
address str - The IPv6 address assigned to the producer instance network interface. This is only assigned when the stack types of both the instance network interface and the consumer subnet are IPv4_IPv6.
- project_
id_ stror_ num - The project id or number of the interface to which the IP was assigned.
- secondary_
ip_ Sequence[str]cidr_ ranges - Alias IP ranges from the same subnetwork.
- status str
- The status of a connected endpoint to this network attachment.
- subnetwork str
- The subnetwork used to assign the IP to the producer instance network interface.
- subnetwork_
cidr_ strrange - The CIDR range of the subnet from which the IPv4 internal IP was allocated from.
- ip
Address String - The IPv4 address assigned to the producer instance network interface. This value will be a range in case of Serverless.
- ipv6Address String
- The IPv6 address assigned to the producer instance network interface. This is only assigned when the stack types of both the instance network interface and the consumer subnet are IPv4_IPv6.
- project
Id StringOr Num - The project id or number of the interface to which the IP was assigned.
- secondary
Ip List<String>Cidr Ranges - Alias IP ranges from the same subnetwork.
- status String
- The status of a connected endpoint to this network attachment.
- subnetwork String
- The subnetwork used to assign the IP to the producer instance network interface.
- subnetwork
Cidr StringRange - The CIDR range of the subnet from which the IPv4 internal IP was allocated from.
NetworkAttachmentConnectionPreference, NetworkAttachmentConnectionPreferenceArgs
- Accept
Automatic - ACCEPT_AUTOMATIC
- Accept
Manual - ACCEPT_MANUAL
- Invalid
- INVALID
- Network
Attachment Connection Preference Accept Automatic - ACCEPT_AUTOMATIC
- Network
Attachment Connection Preference Accept Manual - ACCEPT_MANUAL
- Network
Attachment Connection Preference Invalid - INVALID
- Accept
Automatic - ACCEPT_AUTOMATIC
- Accept
Manual - ACCEPT_MANUAL
- Invalid
- INVALID
- Accept
Automatic - ACCEPT_AUTOMATIC
- Accept
Manual - ACCEPT_MANUAL
- Invalid
- INVALID
- ACCEPT_AUTOMATIC
- ACCEPT_AUTOMATIC
- ACCEPT_MANUAL
- ACCEPT_MANUAL
- INVALID
- INVALID
- "ACCEPT_AUTOMATIC"
- ACCEPT_AUTOMATIC
- "ACCEPT_MANUAL"
- ACCEPT_MANUAL
- "INVALID"
- INVALID
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.