NetworkAssociation
Provides network associations for AWS Client VPN endpoints. For more information on usage, please see the AWS Client VPN Administrator’s Guide.
Example Usage
using Pulumi;
using Aws = Pulumi.Aws;
class MyStack : Stack
{
public MyStack()
{
var example = new Aws.Ec2ClientVpn.NetworkAssociation("example", new Aws.Ec2ClientVpn.NetworkAssociationArgs
{
ClientVpnEndpointId = aws_ec2_client_vpn_endpoint.Example.Id,
SubnetId = aws_subnet.Example.Id,
});
}
}
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v2/go/aws/ec2clientvpn"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ec2clientvpn.NewNetworkAssociation(ctx, "example", &ec2clientvpn.NetworkAssociationArgs{
ClientVpnEndpointId: pulumi.String(aws_ec2_client_vpn_endpoint.Example.Id),
SubnetId: pulumi.String(aws_subnet.Example.Id),
})
if err != nil {
return err
}
return nil
})
}import pulumi
import pulumi_aws as aws
example = aws.ec2clientvpn.NetworkAssociation("example",
client_vpn_endpoint_id=aws_ec2_client_vpn_endpoint["example"]["id"],
subnet_id=aws_subnet["example"]["id"])import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = new aws.ec2clientvpn.NetworkAssociation("example", {
clientVpnEndpointId: aws_ec2_client_vpn_endpoint_example.id,
subnetId: aws_subnet_example.id,
});Create a NetworkAssociation Resource
new NetworkAssociation(name: string, args: NetworkAssociationArgs, opts?: CustomResourceOptions);def NetworkAssociation(resource_name, opts=None, client_vpn_endpoint_id=None, subnet_id=None, __props__=None);func NewNetworkAssociation(ctx *Context, name string, args NetworkAssociationArgs, opts ...ResourceOption) (*NetworkAssociation, error)public NetworkAssociation(string name, NetworkAssociationArgs args, CustomResourceOptions? opts = null)- name string
- The unique name of the resource.
- args NetworkAssociationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- opts ResourceOptions
- A bag of options that control this resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args NetworkAssociationArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args NetworkAssociationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
NetworkAssociation Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.
Inputs
The NetworkAssociation resource accepts the following input properties:
- Client
Vpn stringEndpoint Id The ID of the Client VPN endpoint.
- Subnet
Id string The ID of the subnet to associate with the Client VPN endpoint.
- Client
Vpn stringEndpoint Id The ID of the Client VPN endpoint.
- Subnet
Id string The ID of the subnet to associate with the Client VPN endpoint.
- client
Vpn stringEndpoint Id The ID of the Client VPN endpoint.
- subnet
Id string The ID of the subnet to associate with the Client VPN endpoint.
- client_
vpn_ strendpoint_ id The ID of the Client VPN endpoint.
- subnet_
id str The ID of the subnet to associate with the Client VPN endpoint.
Outputs
All input properties are implicitly available as output properties. Additionally, the NetworkAssociation resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Security
Groups List<string> The IDs of the security groups applied to the target network association.
- Status string
The current state of the target network association.
- Vpc
Id string The ID of the VPC in which the target network (subnet) is located.
- Id string
- The provider-assigned unique ID for this managed resource.
- Security
Groups []string The IDs of the security groups applied to the target network association.
- Status string
The current state of the target network association.
- Vpc
Id string The ID of the VPC in which the target network (subnet) is located.
- id string
- The provider-assigned unique ID for this managed resource.
- security
Groups string[] The IDs of the security groups applied to the target network association.
- status string
The current state of the target network association.
- vpc
Id string The ID of the VPC in which the target network (subnet) is located.
- id str
- The provider-assigned unique ID for this managed resource.
- security_
groups List[str] The IDs of the security groups applied to the target network association.
- status str
The current state of the target network association.
- vpc_
id str The ID of the VPC in which the target network (subnet) is located.
Look up an Existing NetworkAssociation Resource
Get an existing NetworkAssociation resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: NetworkAssociationState, opts?: CustomResourceOptions): NetworkAssociationstatic get(resource_name, id, opts=None, client_vpn_endpoint_id=None, security_groups=None, status=None, subnet_id=None, vpc_id=None, __props__=None);func GetNetworkAssociation(ctx *Context, name string, id IDInput, state *NetworkAssociationState, opts ...ResourceOption) (*NetworkAssociation, error)public static NetworkAssociation Get(string name, Input<string> id, NetworkAssociationState? state, CustomResourceOptions? opts = null)- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
The following state arguments are supported:
- Client
Vpn stringEndpoint Id The ID of the Client VPN endpoint.
- Security
Groups List<string> The IDs of the security groups applied to the target network association.
- Status string
The current state of the target network association.
- Subnet
Id string The ID of the subnet to associate with the Client VPN endpoint.
- Vpc
Id string The ID of the VPC in which the target network (subnet) is located.
- Client
Vpn stringEndpoint Id The ID of the Client VPN endpoint.
- Security
Groups []string The IDs of the security groups applied to the target network association.
- Status string
The current state of the target network association.
- Subnet
Id string The ID of the subnet to associate with the Client VPN endpoint.
- Vpc
Id string The ID of the VPC in which the target network (subnet) is located.
- client
Vpn stringEndpoint Id The ID of the Client VPN endpoint.
- security
Groups string[] The IDs of the security groups applied to the target network association.
- status string
The current state of the target network association.
- subnet
Id string The ID of the subnet to associate with the Client VPN endpoint.
- vpc
Id string The ID of the VPC in which the target network (subnet) is located.
- client_
vpn_ strendpoint_ id The ID of the Client VPN endpoint.
- security_
groups List[str] The IDs of the security groups applied to the target network association.
- status str
The current state of the target network association.
- subnet_
id str The ID of the subnet to associate with the Client VPN endpoint.
- vpc_
id str The ID of the VPC in which the target network (subnet) is located.
Package Details
- Repository
- https://github.com/pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
awsTerraform Provider.