Show / Hide Table of Contents

Class DeliveryChannel

Provides an AWS Config Delivery Channel.

Note: Delivery Channel requires a Configuration Recorder to be present. Use of depends_on (as shown below) is recommended to avoid race conditions.

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
public MyStack()
{
    var bucket = new Aws.S3.Bucket("bucket", new Aws.S3.BucketArgs
    {
        ForceDestroy = true,
    });
    var fooDeliveryChannel = new Aws.Cfg.DeliveryChannel("fooDeliveryChannel", new Aws.Cfg.DeliveryChannelArgs
    {
        S3BucketName = bucket.BucketName,
    });
    var role = new Aws.Iam.Role("role", new Aws.Iam.RoleArgs
    {
        AssumeRolePolicy = @"{
""Version"": ""2012-10-17"",
""Statement"": [
{
  ""Action"": ""sts:AssumeRole"",
  ""Principal"": {
    ""Service"": ""config.amazonaws.com""
  },
  ""Effect"": ""Allow"",
  ""Sid"": """"
}
]
}

",
    });
    var fooRecorder = new Aws.Cfg.Recorder("fooRecorder", new Aws.Cfg.RecorderArgs
    {
        RoleArn = role.Arn,
    });
    var rolePolicy = new Aws.Iam.RolePolicy("rolePolicy", new Aws.Iam.RolePolicyArgs
    {
        Policy = Output.Tuple(bucket.Arn, bucket.Arn).Apply(values =>
        {
            var bucketArn = values.Item1;
            var bucketArn1 = values.Item2;
            return @$"{{
""Version"": ""2012-10-17"",
""Statement"": [
{{
  ""Action"": [
    ""s3:*""
  ],
  ""Effect"": ""Allow"",
  ""Resource"": [
    ""{bucketArn}"",
    ""{bucketArn1}/*""
  ]
}}
]
}}

";
        }),
        Role = role.Id,
    });
}

}
Inheritance
System.Object
Resource
CustomResource
DeliveryChannel
Inherited Members
CustomResource.Id
Resource.GetResourceType()
Resource.GetResourceName()
Resource.Urn
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Pulumi.Aws.Cfg
Assembly: Pulumi.Aws.dll
Syntax
public class DeliveryChannel : CustomResource

Constructors

View Source

DeliveryChannel(String, DeliveryChannelArgs, CustomResourceOptions)

Create a DeliveryChannel resource with the given unique name, arguments, and options.

Declaration
public DeliveryChannel(string name, DeliveryChannelArgs args, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resource

DeliveryChannelArgs args

The arguments used to populate this resource's properties

CustomResourceOptions options

A bag of options that control this resource's behavior

Properties

View Source

Name

The name of the delivery channel. Defaults to default. Changing it recreates the resource.

Declaration
public Output<string> Name { get; }
Property Value
Type Description
Output<System.String>
View Source

S3BucketName

The name of the S3 bucket used to store the configuration history.

Declaration
public Output<string> S3BucketName { get; }
Property Value
Type Description
Output<System.String>
View Source

S3KeyPrefix

The prefix for the specified S3 bucket.

Declaration
public Output<string> S3KeyPrefix { get; }
Property Value
Type Description
Output<System.String>
View Source

SnapshotDeliveryProperties

Options for how AWS Config delivers configuration snapshots. See below

Declaration
public Output<DeliveryChannelSnapshotDeliveryProperties> SnapshotDeliveryProperties { get; }
Property Value
Type Description
Output<DeliveryChannelSnapshotDeliveryProperties>
View Source

SnsTopicArn

The ARN of the SNS topic that AWS Config delivers notifications to.

Declaration
public Output<string> SnsTopicArn { get; }
Property Value
Type Description
Output<System.String>

Methods

View Source

Get(String, Input<String>, DeliveryChannelState, CustomResourceOptions)

Get an existing DeliveryChannel resource's state with the given name, ID, and optional extra properties used to qualify the lookup.

Declaration
public static DeliveryChannel Get(string name, Input<string> id, DeliveryChannelState state = null, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resulting resource.

Input<System.String> id

The unique provider ID of the resource to lookup.

DeliveryChannelState state

Any extra arguments used during the lookup.

CustomResourceOptions options

A bag of options that control this resource's behavior

Returns
Type Description
DeliveryChannel
  • View Source
Back to top Copyright 2016-2020, Pulumi Corporation.