VpcEndpointConnectionNotification

Provides a VPC Endpoint connection notification resource. Connection notifications notify subscribers of VPC Endpoint events.

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
    public MyStack()
    {
        var topic = new Aws.Sns.Topic("topic", new Aws.Sns.TopicArgs
        {
            Policy = @"{
    ""Version"":""2012-10-17"",
    ""Statement"":[{
        ""Effect"": ""Allow"",
        ""Principal"": {
            ""Service"": ""vpce.amazonaws.com""
        },
        ""Action"": ""SNS:Publish"",
        ""Resource"": ""arn:aws:sns:*:*:vpce-notification-topic""
    }]
}
",
        });
        var fooVpcEndpointService = new Aws.Ec2.VpcEndpointService("fooVpcEndpointService", new Aws.Ec2.VpcEndpointServiceArgs
        {
            AcceptanceRequired = false,
            NetworkLoadBalancerArns = 
            {
                aws_lb.Test.Arn,
            },
        });
        var fooVpcEndpointConnectionNotification = new Aws.Ec2.VpcEndpointConnectionNotification("fooVpcEndpointConnectionNotification", new Aws.Ec2.VpcEndpointConnectionNotificationArgs
        {
            VpcEndpointServiceId = fooVpcEndpointService.Id,
            ConnectionNotificationArn = topic.Arn,
            ConnectionEvents = 
            {
                "Accept",
                "Reject",
            },
        });
    }

}

Coming soon!

import pulumi
import pulumi_aws as aws

topic = aws.sns.Topic("topic", policy="""{
    "Version":"2012-10-17",
    "Statement":[{
        "Effect": "Allow",
        "Principal": {
            "Service": "vpce.amazonaws.com"
        },
        "Action": "SNS:Publish",
        "Resource": "arn:aws:sns:*:*:vpce-notification-topic"
    }]
}
""")
foo_vpc_endpoint_service = aws.ec2.VpcEndpointService("fooVpcEndpointService",
    acceptance_required=False,
    network_load_balancer_arns=[aws_lb["test"]["arn"]])
foo_vpc_endpoint_connection_notification = aws.ec2.VpcEndpointConnectionNotification("fooVpcEndpointConnectionNotification",
    vpc_endpoint_service_id=foo_vpc_endpoint_service.id,
    connection_notification_arn=topic.arn,
    connection_events=[
        "Accept",
        "Reject",
    ])
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const topic = new aws.sns.Topic("topic", {policy: `{
    "Version":"2012-10-17",
    "Statement":[{
        "Effect": "Allow",
        "Principal": {
            "Service": "vpce.amazonaws.com"
        },
        "Action": "SNS:Publish",
        "Resource": "arn:aws:sns:*:*:vpce-notification-topic"
    }]
}
`});
const fooVpcEndpointService = new aws.ec2.VpcEndpointService("fooVpcEndpointService", {
    acceptanceRequired: false,
    networkLoadBalancerArns: [aws_lb.test.arn],
});
const fooVpcEndpointConnectionNotification = new aws.ec2.VpcEndpointConnectionNotification("fooVpcEndpointConnectionNotification", {
    vpcEndpointServiceId: fooVpcEndpointService.id,
    connectionNotificationArn: topic.arn,
    connectionEvents: [
        "Accept",
        "Reject",
    ],
});

Create a VpcEndpointConnectionNotification Resource

new VpcEndpointConnectionNotification(name: string, args: VpcEndpointConnectionNotificationArgs, opts?: CustomResourceOptions);
@overload
def VpcEndpointConnectionNotification(resource_name: str,
                                      opts: Optional[ResourceOptions] = None,
                                      connection_events: Optional[Sequence[str]] = None,
                                      connection_notification_arn: Optional[str] = None,
                                      vpc_endpoint_id: Optional[str] = None,
                                      vpc_endpoint_service_id: Optional[str] = None)
@overload
def VpcEndpointConnectionNotification(resource_name: str,
                                      args: VpcEndpointConnectionNotificationArgs,
                                      opts: Optional[ResourceOptions] = None)
func NewVpcEndpointConnectionNotification(ctx *Context, name string, args VpcEndpointConnectionNotificationArgs, opts ...ResourceOption) (*VpcEndpointConnectionNotification, error)
public VpcEndpointConnectionNotification(string name, VpcEndpointConnectionNotificationArgs args, CustomResourceOptions? opts = null)
name string
The unique name of the resource.
args VpcEndpointConnectionNotificationArgs
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 VpcEndpointConnectionNotificationArgs
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 VpcEndpointConnectionNotificationArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args VpcEndpointConnectionNotificationArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.

VpcEndpointConnectionNotification Resource Properties

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

Inputs

The VpcEndpointConnectionNotification resource accepts the following input properties:

ConnectionEvents List<string>
One or more endpoint events for which to receive notifications.
ConnectionNotificationArn string
The ARN of the SNS topic for the notifications.
VpcEndpointId string
The ID of the VPC Endpoint to receive notifications for.
VpcEndpointServiceId string
The ID of the VPC Endpoint Service to receive notifications for.
ConnectionEvents []string
One or more endpoint events for which to receive notifications.
ConnectionNotificationArn string
The ARN of the SNS topic for the notifications.
VpcEndpointId string
The ID of the VPC Endpoint to receive notifications for.
VpcEndpointServiceId string
The ID of the VPC Endpoint Service to receive notifications for.
connectionEvents string[]
One or more endpoint events for which to receive notifications.
connectionNotificationArn string
The ARN of the SNS topic for the notifications.
vpcEndpointId string
The ID of the VPC Endpoint to receive notifications for.
vpcEndpointServiceId string
The ID of the VPC Endpoint Service to receive notifications for.
connection_events Sequence[str]
One or more endpoint events for which to receive notifications.
connection_notification_arn str
The ARN of the SNS topic for the notifications.
vpc_endpoint_id str
The ID of the VPC Endpoint to receive notifications for.
vpc_endpoint_service_id str
The ID of the VPC Endpoint Service to receive notifications for.

Outputs

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

Id string
The provider-assigned unique ID for this managed resource.
NotificationType string
The type of notification.
State string
The state of the notification.
Id string
The provider-assigned unique ID for this managed resource.
NotificationType string
The type of notification.
State string
The state of the notification.
id string
The provider-assigned unique ID for this managed resource.
notificationType string
The type of notification.
state string
The state of the notification.
id str
The provider-assigned unique ID for this managed resource.
notification_type str
The type of notification.
state str
The state of the notification.

Look up an Existing VpcEndpointConnectionNotification Resource

Get an existing VpcEndpointConnectionNotification 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?: VpcEndpointConnectionNotificationState, opts?: CustomResourceOptions): VpcEndpointConnectionNotification
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        connection_events: Optional[Sequence[str]] = None,
        connection_notification_arn: Optional[str] = None,
        notification_type: Optional[str] = None,
        state: Optional[str] = None,
        vpc_endpoint_id: Optional[str] = None,
        vpc_endpoint_service_id: Optional[str] = None) -> VpcEndpointConnectionNotification
func GetVpcEndpointConnectionNotification(ctx *Context, name string, id IDInput, state *VpcEndpointConnectionNotificationState, opts ...ResourceOption) (*VpcEndpointConnectionNotification, error)
public static VpcEndpointConnectionNotification Get(string name, Input<string> id, VpcEndpointConnectionNotificationState? 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:

ConnectionEvents List<string>
One or more endpoint events for which to receive notifications.
ConnectionNotificationArn string
The ARN of the SNS topic for the notifications.
NotificationType string
The type of notification.
State string
The state of the notification.
VpcEndpointId string
The ID of the VPC Endpoint to receive notifications for.
VpcEndpointServiceId string
The ID of the VPC Endpoint Service to receive notifications for.
ConnectionEvents []string
One or more endpoint events for which to receive notifications.
ConnectionNotificationArn string
The ARN of the SNS topic for the notifications.
NotificationType string
The type of notification.
State string
The state of the notification.
VpcEndpointId string
The ID of the VPC Endpoint to receive notifications for.
VpcEndpointServiceId string
The ID of the VPC Endpoint Service to receive notifications for.
connectionEvents string[]
One or more endpoint events for which to receive notifications.
connectionNotificationArn string
The ARN of the SNS topic for the notifications.
notificationType string
The type of notification.
state string
The state of the notification.
vpcEndpointId string
The ID of the VPC Endpoint to receive notifications for.
vpcEndpointServiceId string
The ID of the VPC Endpoint Service to receive notifications for.
connection_events Sequence[str]
One or more endpoint events for which to receive notifications.
connection_notification_arn str
The ARN of the SNS topic for the notifications.
notification_type str
The type of notification.
state str
The state of the notification.
vpc_endpoint_id str
The ID of the VPC Endpoint to receive notifications for.
vpc_endpoint_service_id str
The ID of the VPC Endpoint Service to receive notifications for.

Import

VPC Endpoint connection notifications can be imported using the VPC endpoint connection notification id, e.g.

 $ pulumi import aws:ec2/vpcEndpointConnectionNotification:VpcEndpointConnectionNotification foo vpce-nfn-09e6ed3b4efba2263

Package Details

Repository
https://github.com/pulumi/pulumi-aws
License
Apache-2.0
Notes
This Pulumi package is based on the aws Terraform Provider.