aws.ec2.FlowLog
Provides a VPC/Subnet/ENI/Transit Gateway/Transit Gateway Attachment Flow Log to capture IP traffic for a specific network interface, subnet, or VPC. Logs are sent to a CloudWatch Log Group, a S3 Bucket, or Amazon Kinesis Data Firehose
Example Usage
CloudWatch Logging
using System.Collections.Generic;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var exampleLogGroup = new Aws.CloudWatch.LogGroup("exampleLogGroup");
var assumeRole = Aws.Iam.GetPolicyDocument.Invoke(new()
{
Statements = new[]
{
new Aws.Iam.Inputs.GetPolicyDocumentStatementInputArgs
{
Effect = "Allow",
Principals = new[]
{
new Aws.Iam.Inputs.GetPolicyDocumentStatementPrincipalInputArgs
{
Type = "Service",
Identifiers = new[]
{
"vpc-flow-logs.amazonaws.com",
},
},
},
Actions = new[]
{
"sts:AssumeRole",
},
},
},
});
var exampleRole = new Aws.Iam.Role("exampleRole", new()
{
AssumeRolePolicy = assumeRole.Apply(getPolicyDocumentResult => getPolicyDocumentResult.Json),
});
var exampleFlowLog = new Aws.Ec2.FlowLog("exampleFlowLog", new()
{
IamRoleArn = exampleRole.Arn,
LogDestination = exampleLogGroup.Arn,
TrafficType = "ALL",
VpcId = aws_vpc.Example.Id,
});
var examplePolicyDocument = Aws.Iam.GetPolicyDocument.Invoke(new()
{
Statements = new[]
{
new Aws.Iam.Inputs.GetPolicyDocumentStatementInputArgs
{
Effect = "Allow",
Actions = new[]
{
"logs:CreateLogGroup",
"logs:CreateLogStream",
"logs:PutLogEvents",
"logs:DescribeLogGroups",
"logs:DescribeLogStreams",
},
Resources = new[]
{
"*",
},
},
},
});
var exampleRolePolicy = new Aws.Iam.RolePolicy("exampleRolePolicy", new()
{
Role = exampleRole.Id,
Policy = examplePolicyDocument.Apply(getPolicyDocumentResult => getPolicyDocumentResult.Json),
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/cloudwatch"
"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/ec2"
"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/iam"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
exampleLogGroup, err := cloudwatch.NewLogGroup(ctx, "exampleLogGroup", nil)
if err != nil {
return err
}
assumeRole, err := iam.GetPolicyDocument(ctx, &iam.GetPolicyDocumentArgs{
Statements: []iam.GetPolicyDocumentStatement{
{
Effect: pulumi.StringRef("Allow"),
Principals: []iam.GetPolicyDocumentStatementPrincipal{
{
Type: "Service",
Identifiers: []string{
"vpc-flow-logs.amazonaws.com",
},
},
},
Actions: []string{
"sts:AssumeRole",
},
},
},
}, nil)
if err != nil {
return err
}
exampleRole, err := iam.NewRole(ctx, "exampleRole", &iam.RoleArgs{
AssumeRolePolicy: *pulumi.String(assumeRole.Json),
})
if err != nil {
return err
}
_, err = ec2.NewFlowLog(ctx, "exampleFlowLog", &ec2.FlowLogArgs{
IamRoleArn: exampleRole.Arn,
LogDestination: exampleLogGroup.Arn,
TrafficType: pulumi.String("ALL"),
VpcId: pulumi.Any(aws_vpc.Example.Id),
})
if err != nil {
return err
}
examplePolicyDocument, err := iam.GetPolicyDocument(ctx, &iam.GetPolicyDocumentArgs{
Statements: []iam.GetPolicyDocumentStatement{
{
Effect: pulumi.StringRef("Allow"),
Actions: []string{
"logs:CreateLogGroup",
"logs:CreateLogStream",
"logs:PutLogEvents",
"logs:DescribeLogGroups",
"logs:DescribeLogStreams",
},
Resources: []string{
"*",
},
},
},
}, nil)
if err != nil {
return err
}
_, err = iam.NewRolePolicy(ctx, "exampleRolePolicy", &iam.RolePolicyArgs{
Role: exampleRole.ID(),
Policy: *pulumi.String(examplePolicyDocument.Json),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.cloudwatch.LogGroup;
import com.pulumi.aws.iam.IamFunctions;
import com.pulumi.aws.iam.inputs.GetPolicyDocumentArgs;
import com.pulumi.aws.iam.Role;
import com.pulumi.aws.iam.RoleArgs;
import com.pulumi.aws.ec2.FlowLog;
import com.pulumi.aws.ec2.FlowLogArgs;
import com.pulumi.aws.iam.RolePolicy;
import com.pulumi.aws.iam.RolePolicyArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var exampleLogGroup = new LogGroup("exampleLogGroup");
final var assumeRole = IamFunctions.getPolicyDocument(GetPolicyDocumentArgs.builder()
.statements(GetPolicyDocumentStatementArgs.builder()
.effect("Allow")
.principals(GetPolicyDocumentStatementPrincipalArgs.builder()
.type("Service")
.identifiers("vpc-flow-logs.amazonaws.com")
.build())
.actions("sts:AssumeRole")
.build())
.build());
var exampleRole = new Role("exampleRole", RoleArgs.builder()
.assumeRolePolicy(assumeRole.applyValue(getPolicyDocumentResult -> getPolicyDocumentResult.json()))
.build());
var exampleFlowLog = new FlowLog("exampleFlowLog", FlowLogArgs.builder()
.iamRoleArn(exampleRole.arn())
.logDestination(exampleLogGroup.arn())
.trafficType("ALL")
.vpcId(aws_vpc.example().id())
.build());
final var examplePolicyDocument = IamFunctions.getPolicyDocument(GetPolicyDocumentArgs.builder()
.statements(GetPolicyDocumentStatementArgs.builder()
.effect("Allow")
.actions(
"logs:CreateLogGroup",
"logs:CreateLogStream",
"logs:PutLogEvents",
"logs:DescribeLogGroups",
"logs:DescribeLogStreams")
.resources("*")
.build())
.build());
var exampleRolePolicy = new RolePolicy("exampleRolePolicy", RolePolicyArgs.builder()
.role(exampleRole.id())
.policy(examplePolicyDocument.applyValue(getPolicyDocumentResult -> getPolicyDocumentResult.json()))
.build());
}
}
import pulumi
import pulumi_aws as aws
example_log_group = aws.cloudwatch.LogGroup("exampleLogGroup")
assume_role = aws.iam.get_policy_document(statements=[aws.iam.GetPolicyDocumentStatementArgs(
effect="Allow",
principals=[aws.iam.GetPolicyDocumentStatementPrincipalArgs(
type="Service",
identifiers=["vpc-flow-logs.amazonaws.com"],
)],
actions=["sts:AssumeRole"],
)])
example_role = aws.iam.Role("exampleRole", assume_role_policy=assume_role.json)
example_flow_log = aws.ec2.FlowLog("exampleFlowLog",
iam_role_arn=example_role.arn,
log_destination=example_log_group.arn,
traffic_type="ALL",
vpc_id=aws_vpc["example"]["id"])
example_policy_document = aws.iam.get_policy_document(statements=[aws.iam.GetPolicyDocumentStatementArgs(
effect="Allow",
actions=[
"logs:CreateLogGroup",
"logs:CreateLogStream",
"logs:PutLogEvents",
"logs:DescribeLogGroups",
"logs:DescribeLogStreams",
],
resources=["*"],
)])
example_role_policy = aws.iam.RolePolicy("exampleRolePolicy",
role=example_role.id,
policy=example_policy_document.json)
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const exampleLogGroup = new aws.cloudwatch.LogGroup("exampleLogGroup", {});
const assumeRole = aws.iam.getPolicyDocument({
statements: [{
effect: "Allow",
principals: [{
type: "Service",
identifiers: ["vpc-flow-logs.amazonaws.com"],
}],
actions: ["sts:AssumeRole"],
}],
});
const exampleRole = new aws.iam.Role("exampleRole", {assumeRolePolicy: assumeRole.then(assumeRole => assumeRole.json)});
const exampleFlowLog = new aws.ec2.FlowLog("exampleFlowLog", {
iamRoleArn: exampleRole.arn,
logDestination: exampleLogGroup.arn,
trafficType: "ALL",
vpcId: aws_vpc.example.id,
});
const examplePolicyDocument = aws.iam.getPolicyDocument({
statements: [{
effect: "Allow",
actions: [
"logs:CreateLogGroup",
"logs:CreateLogStream",
"logs:PutLogEvents",
"logs:DescribeLogGroups",
"logs:DescribeLogStreams",
],
resources: ["*"],
}],
});
const exampleRolePolicy = new aws.iam.RolePolicy("exampleRolePolicy", {
role: exampleRole.id,
policy: examplePolicyDocument.then(examplePolicyDocument => examplePolicyDocument.json),
});
resources:
exampleFlowLog:
type: aws:ec2:FlowLog
properties:
iamRoleArn: ${exampleRole.arn}
logDestination: ${exampleLogGroup.arn}
trafficType: ALL
vpcId: ${aws_vpc.example.id}
exampleLogGroup:
type: aws:cloudwatch:LogGroup
exampleRole:
type: aws:iam:Role
properties:
assumeRolePolicy: ${assumeRole.json}
exampleRolePolicy:
type: aws:iam:RolePolicy
properties:
role: ${exampleRole.id}
policy: ${examplePolicyDocument.json}
variables:
assumeRole:
fn::invoke:
Function: aws:iam:getPolicyDocument
Arguments:
statements:
- effect: Allow
principals:
- type: Service
identifiers:
- vpc-flow-logs.amazonaws.com
actions:
- sts:AssumeRole
examplePolicyDocument:
fn::invoke:
Function: aws:iam:getPolicyDocument
Arguments:
statements:
- effect: Allow
actions:
- logs:CreateLogGroup
- logs:CreateLogStream
- logs:PutLogEvents
- logs:DescribeLogGroups
- logs:DescribeLogStreams
resources:
- '*'
Amazon Kinesis Data Firehose logging
using System.Collections.Generic;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var exampleBucketV2 = new Aws.S3.BucketV2("exampleBucketV2");
var exampleFlowLog = new Aws.Ec2.FlowLog("exampleFlowLog", new()
{
LogDestination = exampleBucketV2.Arn,
LogDestinationType = "s3",
TrafficType = "ALL",
VpcId = aws_vpc.Example.Id,
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/ec2"
"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/s3"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
exampleBucketV2, err := s3.NewBucketV2(ctx, "exampleBucketV2", nil)
if err != nil {
return err
}
_, err = ec2.NewFlowLog(ctx, "exampleFlowLog", &ec2.FlowLogArgs{
LogDestination: exampleBucketV2.Arn,
LogDestinationType: pulumi.String("s3"),
TrafficType: pulumi.String("ALL"),
VpcId: pulumi.Any(aws_vpc.Example.Id),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.s3.BucketV2;
import com.pulumi.aws.iam.IamFunctions;
import com.pulumi.aws.iam.inputs.GetPolicyDocumentArgs;
import com.pulumi.aws.iam.Role;
import com.pulumi.aws.iam.RoleArgs;
import com.pulumi.aws.kinesis.FirehoseDeliveryStream;
import com.pulumi.aws.kinesis.FirehoseDeliveryStreamArgs;
import com.pulumi.aws.kinesis.inputs.FirehoseDeliveryStreamExtendedS3ConfigurationArgs;
import com.pulumi.aws.ec2.FlowLog;
import com.pulumi.aws.ec2.FlowLogArgs;
import com.pulumi.aws.s3.BucketAclV2;
import com.pulumi.aws.s3.BucketAclV2Args;
import com.pulumi.aws.iam.RolePolicy;
import com.pulumi.aws.iam.RolePolicyArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var exampleBucketV2 = new BucketV2("exampleBucketV2");
final var assumeRole = IamFunctions.getPolicyDocument(GetPolicyDocumentArgs.builder()
.statements(GetPolicyDocumentStatementArgs.builder()
.effect("Allow")
.principals(GetPolicyDocumentStatementPrincipalArgs.builder()
.type("Service")
.identifiers("firehose.amazonaws.com")
.build())
.actions("sts:AssumeRole")
.build())
.build());
var exampleRole = new Role("exampleRole", RoleArgs.builder()
.assumeRolePolicy(assumeRole.applyValue(getPolicyDocumentResult -> getPolicyDocumentResult.json()))
.build());
var exampleFirehoseDeliveryStream = new FirehoseDeliveryStream("exampleFirehoseDeliveryStream", FirehoseDeliveryStreamArgs.builder()
.destination("extended_s3")
.extendedS3Configuration(FirehoseDeliveryStreamExtendedS3ConfigurationArgs.builder()
.roleArn(exampleRole.arn())
.bucketArn(exampleBucketV2.arn())
.build())
.tags(Map.of("LogDeliveryEnabled", "true"))
.build());
var exampleFlowLog = new FlowLog("exampleFlowLog", FlowLogArgs.builder()
.logDestination(exampleFirehoseDeliveryStream.arn())
.logDestinationType("kinesis-data-firehose")
.trafficType("ALL")
.vpcId(aws_vpc.example().id())
.build());
var exampleBucketAclV2 = new BucketAclV2("exampleBucketAclV2", BucketAclV2Args.builder()
.bucket(exampleBucketV2.id())
.acl("private")
.build());
final var examplePolicyDocument = IamFunctions.getPolicyDocument(GetPolicyDocumentArgs.builder()
.effect("Allow")
.actions(
"logs:CreateLogDelivery",
"logs:DeleteLogDelivery",
"logs:ListLogDeliveries",
"logs:GetLogDelivery",
"firehose:TagDeliveryStream")
.resources("*")
.build());
var exampleRolePolicy = new RolePolicy("exampleRolePolicy", RolePolicyArgs.builder()
.role(exampleRole.id())
.policy(examplePolicyDocument.applyValue(getPolicyDocumentResult -> getPolicyDocumentResult.json()))
.build());
}
}
import pulumi
import pulumi_aws as aws
example_bucket_v2 = aws.s3.BucketV2("exampleBucketV2")
example_flow_log = aws.ec2.FlowLog("exampleFlowLog",
log_destination=example_bucket_v2.arn,
log_destination_type="s3",
traffic_type="ALL",
vpc_id=aws_vpc["example"]["id"])
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const exampleBucketV2 = new aws.s3.BucketV2("exampleBucketV2", {});
const exampleFlowLog = new aws.ec2.FlowLog("exampleFlowLog", {
logDestination: exampleBucketV2.arn,
logDestinationType: "s3",
trafficType: "ALL",
vpcId: aws_vpc.example.id,
});
resources:
exampleFlowLog:
type: aws:ec2:FlowLog
properties:
logDestination: ${exampleFirehoseDeliveryStream.arn}
logDestinationType: kinesis-data-firehose
trafficType: ALL
vpcId: ${aws_vpc.example.id}
exampleFirehoseDeliveryStream:
type: aws:kinesis:FirehoseDeliveryStream
properties:
destination: extended_s3
extendedS3Configuration:
roleArn: ${exampleRole.arn}
bucketArn: ${exampleBucketV2.arn}
tags:
LogDeliveryEnabled: 'true'
exampleBucketV2:
type: aws:s3:BucketV2
exampleBucketAclV2:
type: aws:s3:BucketAclV2
properties:
bucket: ${exampleBucketV2.id}
acl: private
exampleRole:
type: aws:iam:Role
properties:
assumeRolePolicy: ${assumeRole.json}
exampleRolePolicy:
type: aws:iam:RolePolicy
properties:
role: ${exampleRole.id}
policy: ${examplePolicyDocument.json}
variables:
assumeRole:
fn::invoke:
Function: aws:iam:getPolicyDocument
Arguments:
statements:
- effect: Allow
principals:
- type: Service
identifiers:
- firehose.amazonaws.com
actions:
- sts:AssumeRole
examplePolicyDocument:
fn::invoke:
Function: aws:iam:getPolicyDocument
Arguments:
effect: Allow
actions:
- logs:CreateLogDelivery
- logs:DeleteLogDelivery
- logs:ListLogDeliveries
- logs:GetLogDelivery
- firehose:TagDeliveryStream
resources:
- '*'
S3 Logging
using System.Collections.Generic;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var exampleBucketV2 = new Aws.S3.BucketV2("exampleBucketV2");
var exampleFlowLog = new Aws.Ec2.FlowLog("exampleFlowLog", new()
{
LogDestination = exampleBucketV2.Arn,
LogDestinationType = "s3",
TrafficType = "ALL",
VpcId = aws_vpc.Example.Id,
DestinationOptions = new Aws.Ec2.Inputs.FlowLogDestinationOptionsArgs
{
FileFormat = "parquet",
PerHourPartition = true,
},
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/ec2"
"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/s3"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
exampleBucketV2, err := s3.NewBucketV2(ctx, "exampleBucketV2", nil)
if err != nil {
return err
}
_, err = ec2.NewFlowLog(ctx, "exampleFlowLog", &ec2.FlowLogArgs{
LogDestination: exampleBucketV2.Arn,
LogDestinationType: pulumi.String("s3"),
TrafficType: pulumi.String("ALL"),
VpcId: pulumi.Any(aws_vpc.Example.Id),
DestinationOptions: &ec2.FlowLogDestinationOptionsArgs{
FileFormat: pulumi.String("parquet"),
PerHourPartition: pulumi.Bool(true),
},
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.s3.BucketV2;
import com.pulumi.aws.ec2.FlowLog;
import com.pulumi.aws.ec2.FlowLogArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var exampleBucketV2 = new BucketV2("exampleBucketV2");
var exampleFlowLog = new FlowLog("exampleFlowLog", FlowLogArgs.builder()
.logDestination(exampleBucketV2.arn())
.logDestinationType("s3")
.trafficType("ALL")
.vpcId(aws_vpc.example().id())
.build());
}
}
import pulumi
import pulumi_aws as aws
example_bucket_v2 = aws.s3.BucketV2("exampleBucketV2")
example_flow_log = aws.ec2.FlowLog("exampleFlowLog",
log_destination=example_bucket_v2.arn,
log_destination_type="s3",
traffic_type="ALL",
vpc_id=aws_vpc["example"]["id"],
destination_options=aws.ec2.FlowLogDestinationOptionsArgs(
file_format="parquet",
per_hour_partition=True,
))
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const exampleBucketV2 = new aws.s3.BucketV2("exampleBucketV2", {});
const exampleFlowLog = new aws.ec2.FlowLog("exampleFlowLog", {
logDestination: exampleBucketV2.arn,
logDestinationType: "s3",
trafficType: "ALL",
vpcId: aws_vpc.example.id,
destinationOptions: {
fileFormat: "parquet",
perHourPartition: true,
},
});
resources:
exampleFlowLog:
type: aws:ec2:FlowLog
properties:
logDestination: ${exampleBucketV2.arn}
logDestinationType: s3
trafficType: ALL
vpcId: ${aws_vpc.example.id}
exampleBucketV2:
type: aws:s3:BucketV2
S3 Logging in Apache Parquet format with per-hour partitions
Coming soon!
Coming soon!
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.s3.BucketV2;
import com.pulumi.aws.ec2.FlowLog;
import com.pulumi.aws.ec2.FlowLogArgs;
import com.pulumi.aws.ec2.inputs.FlowLogDestinationOptionsArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var exampleBucketV2 = new BucketV2("exampleBucketV2");
var exampleFlowLog = new FlowLog("exampleFlowLog", FlowLogArgs.builder()
.logDestination(exampleBucketV2.arn())
.logDestinationType("s3")
.trafficType("ALL")
.vpcId(aws_vpc.example().id())
.destinationOptions(FlowLogDestinationOptionsArgs.builder()
.fileFormat("parquet")
.perHourPartition(true)
.build())
.build());
}
}
Coming soon!
Coming soon!
resources:
exampleFlowLog:
type: aws:ec2:FlowLog
properties:
logDestination: ${exampleBucketV2.arn}
logDestinationType: s3
trafficType: ALL
vpcId: ${aws_vpc.example.id}
destinationOptions:
fileFormat: parquet
perHourPartition: true
exampleBucketV2:
type: aws:s3:BucketV2
Create FlowLog Resource
new FlowLog(name: string, args?: FlowLogArgs, opts?: CustomResourceOptions);
@overload
def FlowLog(resource_name: str,
opts: Optional[ResourceOptions] = None,
deliver_cross_account_role: Optional[str] = None,
destination_options: Optional[FlowLogDestinationOptionsArgs] = None,
eni_id: Optional[str] = None,
iam_role_arn: Optional[str] = None,
log_destination: Optional[str] = None,
log_destination_type: Optional[str] = None,
log_format: Optional[str] = None,
log_group_name: Optional[str] = None,
max_aggregation_interval: Optional[int] = None,
subnet_id: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None,
traffic_type: Optional[str] = None,
transit_gateway_attachment_id: Optional[str] = None,
transit_gateway_id: Optional[str] = None,
vpc_id: Optional[str] = None)
@overload
def FlowLog(resource_name: str,
args: Optional[FlowLogArgs] = None,
opts: Optional[ResourceOptions] = None)
func NewFlowLog(ctx *Context, name string, args *FlowLogArgs, opts ...ResourceOption) (*FlowLog, error)
public FlowLog(string name, FlowLogArgs? args = null, CustomResourceOptions? opts = null)
public FlowLog(String name, FlowLogArgs args)
public FlowLog(String name, FlowLogArgs args, CustomResourceOptions options)
type: aws:ec2:FlowLog
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args FlowLogArgs
- 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 FlowLogArgs
- 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 FlowLogArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args FlowLogArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args FlowLogArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
FlowLog Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The FlowLog resource accepts the following input properties:
- Deliver
Cross stringAccount Role ARN of the IAM role that allows Amazon EC2 to publish flow logs across accounts.
- Destination
Options Pulumi.Aws. Ec2. Inputs. Flow Log Destination Options Args Describes the destination options for a flow log. More details below.
- Eni
Id string Elastic Network Interface ID to attach to
- Iam
Role stringArn The ARN for the IAM role that's used to post flow logs to a CloudWatch Logs log group
- Log
Destination string The ARN of the logging destination. Either
log_destination
orlog_group_name
must be set.- Log
Destination stringType The type of the logging destination. Valid values:
cloud-watch-logs
,s3
,kinesis-data-firehose
. Default:cloud-watch-logs
.- Log
Format string The fields to include in the flow log record, in the order in which they should appear.
- Log
Group stringName Deprecated: Use
log_destination
instead. The name of the CloudWatch log group. Eitherlog_group_name
orlog_destination
must be set.use 'log_destination' argument instead
- Max
Aggregation intInterval The maximum interval of time during which a flow of packets is captured and aggregated into a flow log record. Valid Values:
60
seconds (1 minute) or600
seconds (10 minutes). Default:600
. Whentransit_gateway_id
ortransit_gateway_attachment_id
is specified,max_aggregation_interval
must be 60 seconds (1 minute).- Subnet
Id string Subnet ID to attach to
- Dictionary<string, string>
Key-value map of resource tags. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.- Traffic
Type string The type of traffic to capture. Valid values:
ACCEPT
,REJECT
,ALL
.- Transit
Gateway stringAttachment Id Transit Gateway Attachment ID to attach to
- Transit
Gateway stringId Transit Gateway ID to attach to
- Vpc
Id string VPC ID to attach to
- Deliver
Cross stringAccount Role ARN of the IAM role that allows Amazon EC2 to publish flow logs across accounts.
- Destination
Options FlowLog Destination Options Args Describes the destination options for a flow log. More details below.
- Eni
Id string Elastic Network Interface ID to attach to
- Iam
Role stringArn The ARN for the IAM role that's used to post flow logs to a CloudWatch Logs log group
- Log
Destination string The ARN of the logging destination. Either
log_destination
orlog_group_name
must be set.- Log
Destination stringType The type of the logging destination. Valid values:
cloud-watch-logs
,s3
,kinesis-data-firehose
. Default:cloud-watch-logs
.- Log
Format string The fields to include in the flow log record, in the order in which they should appear.
- Log
Group stringName Deprecated: Use
log_destination
instead. The name of the CloudWatch log group. Eitherlog_group_name
orlog_destination
must be set.use 'log_destination' argument instead
- Max
Aggregation intInterval The maximum interval of time during which a flow of packets is captured and aggregated into a flow log record. Valid Values:
60
seconds (1 minute) or600
seconds (10 minutes). Default:600
. Whentransit_gateway_id
ortransit_gateway_attachment_id
is specified,max_aggregation_interval
must be 60 seconds (1 minute).- Subnet
Id string Subnet ID to attach to
- map[string]string
Key-value map of resource tags. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.- Traffic
Type string The type of traffic to capture. Valid values:
ACCEPT
,REJECT
,ALL
.- Transit
Gateway stringAttachment Id Transit Gateway Attachment ID to attach to
- Transit
Gateway stringId Transit Gateway ID to attach to
- Vpc
Id string VPC ID to attach to
- deliver
Cross StringAccount Role ARN of the IAM role that allows Amazon EC2 to publish flow logs across accounts.
- destination
Options FlowLog Destination Options Args Describes the destination options for a flow log. More details below.
- eni
Id String Elastic Network Interface ID to attach to
- iam
Role StringArn The ARN for the IAM role that's used to post flow logs to a CloudWatch Logs log group
- log
Destination String The ARN of the logging destination. Either
log_destination
orlog_group_name
must be set.- log
Destination StringType The type of the logging destination. Valid values:
cloud-watch-logs
,s3
,kinesis-data-firehose
. Default:cloud-watch-logs
.- log
Format String The fields to include in the flow log record, in the order in which they should appear.
- log
Group StringName Deprecated: Use
log_destination
instead. The name of the CloudWatch log group. Eitherlog_group_name
orlog_destination
must be set.use 'log_destination' argument instead
- max
Aggregation IntegerInterval The maximum interval of time during which a flow of packets is captured and aggregated into a flow log record. Valid Values:
60
seconds (1 minute) or600
seconds (10 minutes). Default:600
. Whentransit_gateway_id
ortransit_gateway_attachment_id
is specified,max_aggregation_interval
must be 60 seconds (1 minute).- subnet
Id String Subnet ID to attach to
- Map<String,String>
Key-value map of resource tags. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.- traffic
Type String The type of traffic to capture. Valid values:
ACCEPT
,REJECT
,ALL
.- transit
Gateway StringAttachment Id Transit Gateway Attachment ID to attach to
- transit
Gateway StringId Transit Gateway ID to attach to
- vpc
Id String VPC ID to attach to
- deliver
Cross stringAccount Role ARN of the IAM role that allows Amazon EC2 to publish flow logs across accounts.
- destination
Options FlowLog Destination Options Args Describes the destination options for a flow log. More details below.
- eni
Id string Elastic Network Interface ID to attach to
- iam
Role stringArn The ARN for the IAM role that's used to post flow logs to a CloudWatch Logs log group
- log
Destination string The ARN of the logging destination. Either
log_destination
orlog_group_name
must be set.- log
Destination stringType The type of the logging destination. Valid values:
cloud-watch-logs
,s3
,kinesis-data-firehose
. Default:cloud-watch-logs
.- log
Format string The fields to include in the flow log record, in the order in which they should appear.
- log
Group stringName Deprecated: Use
log_destination
instead. The name of the CloudWatch log group. Eitherlog_group_name
orlog_destination
must be set.use 'log_destination' argument instead
- max
Aggregation numberInterval The maximum interval of time during which a flow of packets is captured and aggregated into a flow log record. Valid Values:
60
seconds (1 minute) or600
seconds (10 minutes). Default:600
. Whentransit_gateway_id
ortransit_gateway_attachment_id
is specified,max_aggregation_interval
must be 60 seconds (1 minute).- subnet
Id string Subnet ID to attach to
- {[key: string]: string}
Key-value map of resource tags. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.- traffic
Type string The type of traffic to capture. Valid values:
ACCEPT
,REJECT
,ALL
.- transit
Gateway stringAttachment Id Transit Gateway Attachment ID to attach to
- transit
Gateway stringId Transit Gateway ID to attach to
- vpc
Id string VPC ID to attach to
- deliver_
cross_ straccount_ role ARN of the IAM role that allows Amazon EC2 to publish flow logs across accounts.
- destination_
options FlowLog Destination Options Args Describes the destination options for a flow log. More details below.
- eni_
id str Elastic Network Interface ID to attach to
- iam_
role_ strarn The ARN for the IAM role that's used to post flow logs to a CloudWatch Logs log group
- log_
destination str The ARN of the logging destination. Either
log_destination
orlog_group_name
must be set.- log_
destination_ strtype The type of the logging destination. Valid values:
cloud-watch-logs
,s3
,kinesis-data-firehose
. Default:cloud-watch-logs
.- log_
format str The fields to include in the flow log record, in the order in which they should appear.
- log_
group_ strname Deprecated: Use
log_destination
instead. The name of the CloudWatch log group. Eitherlog_group_name
orlog_destination
must be set.use 'log_destination' argument instead
- max_
aggregation_ intinterval The maximum interval of time during which a flow of packets is captured and aggregated into a flow log record. Valid Values:
60
seconds (1 minute) or600
seconds (10 minutes). Default:600
. Whentransit_gateway_id
ortransit_gateway_attachment_id
is specified,max_aggregation_interval
must be 60 seconds (1 minute).- subnet_
id str Subnet ID to attach to
- Mapping[str, str]
Key-value map of resource tags. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.- traffic_
type str The type of traffic to capture. Valid values:
ACCEPT
,REJECT
,ALL
.- transit_
gateway_ strattachment_ id Transit Gateway Attachment ID to attach to
- transit_
gateway_ strid Transit Gateway ID to attach to
- vpc_
id str VPC ID to attach to
- deliver
Cross StringAccount Role ARN of the IAM role that allows Amazon EC2 to publish flow logs across accounts.
- destination
Options Property Map Describes the destination options for a flow log. More details below.
- eni
Id String Elastic Network Interface ID to attach to
- iam
Role StringArn The ARN for the IAM role that's used to post flow logs to a CloudWatch Logs log group
- log
Destination String The ARN of the logging destination. Either
log_destination
orlog_group_name
must be set.- log
Destination StringType The type of the logging destination. Valid values:
cloud-watch-logs
,s3
,kinesis-data-firehose
. Default:cloud-watch-logs
.- log
Format String The fields to include in the flow log record, in the order in which they should appear.
- log
Group StringName Deprecated: Use
log_destination
instead. The name of the CloudWatch log group. Eitherlog_group_name
orlog_destination
must be set.use 'log_destination' argument instead
- max
Aggregation NumberInterval The maximum interval of time during which a flow of packets is captured and aggregated into a flow log record. Valid Values:
60
seconds (1 minute) or600
seconds (10 minutes). Default:600
. Whentransit_gateway_id
ortransit_gateway_attachment_id
is specified,max_aggregation_interval
must be 60 seconds (1 minute).- subnet
Id String Subnet ID to attach to
- Map<String>
Key-value map of resource tags. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.- traffic
Type String The type of traffic to capture. Valid values:
ACCEPT
,REJECT
,ALL
.- transit
Gateway StringAttachment Id Transit Gateway Attachment ID to attach to
- transit
Gateway StringId Transit Gateway ID to attach to
- vpc
Id String VPC ID to attach to
Outputs
All input properties are implicitly available as output properties. Additionally, the FlowLog resource produces the following output properties:
Look up Existing FlowLog Resource
Get an existing FlowLog 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?: FlowLogState, opts?: CustomResourceOptions): FlowLog
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
arn: Optional[str] = None,
deliver_cross_account_role: Optional[str] = None,
destination_options: Optional[FlowLogDestinationOptionsArgs] = None,
eni_id: Optional[str] = None,
iam_role_arn: Optional[str] = None,
log_destination: Optional[str] = None,
log_destination_type: Optional[str] = None,
log_format: Optional[str] = None,
log_group_name: Optional[str] = None,
max_aggregation_interval: Optional[int] = None,
subnet_id: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None,
tags_all: Optional[Mapping[str, str]] = None,
traffic_type: Optional[str] = None,
transit_gateway_attachment_id: Optional[str] = None,
transit_gateway_id: Optional[str] = None,
vpc_id: Optional[str] = None) -> FlowLog
func GetFlowLog(ctx *Context, name string, id IDInput, state *FlowLogState, opts ...ResourceOption) (*FlowLog, error)
public static FlowLog Get(string name, Input<string> id, FlowLogState? state, CustomResourceOptions? opts = null)
public static FlowLog get(String name, Output<String> id, FlowLogState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- 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.
- 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.
- Arn string
The ARN of the Flow Log.
- Deliver
Cross stringAccount Role ARN of the IAM role that allows Amazon EC2 to publish flow logs across accounts.
- Destination
Options Pulumi.Aws. Ec2. Inputs. Flow Log Destination Options Args Describes the destination options for a flow log. More details below.
- Eni
Id string Elastic Network Interface ID to attach to
- Iam
Role stringArn The ARN for the IAM role that's used to post flow logs to a CloudWatch Logs log group
- Log
Destination string The ARN of the logging destination. Either
log_destination
orlog_group_name
must be set.- Log
Destination stringType The type of the logging destination. Valid values:
cloud-watch-logs
,s3
,kinesis-data-firehose
. Default:cloud-watch-logs
.- Log
Format string The fields to include in the flow log record, in the order in which they should appear.
- Log
Group stringName Deprecated: Use
log_destination
instead. The name of the CloudWatch log group. Eitherlog_group_name
orlog_destination
must be set.use 'log_destination' argument instead
- Max
Aggregation intInterval The maximum interval of time during which a flow of packets is captured and aggregated into a flow log record. Valid Values:
60
seconds (1 minute) or600
seconds (10 minutes). Default:600
. Whentransit_gateway_id
ortransit_gateway_attachment_id
is specified,max_aggregation_interval
must be 60 seconds (1 minute).- Subnet
Id string Subnet ID to attach to
- Dictionary<string, string>
Key-value map of resource tags. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.- Dictionary<string, string>
A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.- Traffic
Type string The type of traffic to capture. Valid values:
ACCEPT
,REJECT
,ALL
.- Transit
Gateway stringAttachment Id Transit Gateway Attachment ID to attach to
- Transit
Gateway stringId Transit Gateway ID to attach to
- Vpc
Id string VPC ID to attach to
- Arn string
The ARN of the Flow Log.
- Deliver
Cross stringAccount Role ARN of the IAM role that allows Amazon EC2 to publish flow logs across accounts.
- Destination
Options FlowLog Destination Options Args Describes the destination options for a flow log. More details below.
- Eni
Id string Elastic Network Interface ID to attach to
- Iam
Role stringArn The ARN for the IAM role that's used to post flow logs to a CloudWatch Logs log group
- Log
Destination string The ARN of the logging destination. Either
log_destination
orlog_group_name
must be set.- Log
Destination stringType The type of the logging destination. Valid values:
cloud-watch-logs
,s3
,kinesis-data-firehose
. Default:cloud-watch-logs
.- Log
Format string The fields to include in the flow log record, in the order in which they should appear.
- Log
Group stringName Deprecated: Use
log_destination
instead. The name of the CloudWatch log group. Eitherlog_group_name
orlog_destination
must be set.use 'log_destination' argument instead
- Max
Aggregation intInterval The maximum interval of time during which a flow of packets is captured and aggregated into a flow log record. Valid Values:
60
seconds (1 minute) or600
seconds (10 minutes). Default:600
. Whentransit_gateway_id
ortransit_gateway_attachment_id
is specified,max_aggregation_interval
must be 60 seconds (1 minute).- Subnet
Id string Subnet ID to attach to
- map[string]string
Key-value map of resource tags. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.- map[string]string
A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.- Traffic
Type string The type of traffic to capture. Valid values:
ACCEPT
,REJECT
,ALL
.- Transit
Gateway stringAttachment Id Transit Gateway Attachment ID to attach to
- Transit
Gateway stringId Transit Gateway ID to attach to
- Vpc
Id string VPC ID to attach to
- arn String
The ARN of the Flow Log.
- deliver
Cross StringAccount Role ARN of the IAM role that allows Amazon EC2 to publish flow logs across accounts.
- destination
Options FlowLog Destination Options Args Describes the destination options for a flow log. More details below.
- eni
Id String Elastic Network Interface ID to attach to
- iam
Role StringArn The ARN for the IAM role that's used to post flow logs to a CloudWatch Logs log group
- log
Destination String The ARN of the logging destination. Either
log_destination
orlog_group_name
must be set.- log
Destination StringType The type of the logging destination. Valid values:
cloud-watch-logs
,s3
,kinesis-data-firehose
. Default:cloud-watch-logs
.- log
Format String The fields to include in the flow log record, in the order in which they should appear.
- log
Group StringName Deprecated: Use
log_destination
instead. The name of the CloudWatch log group. Eitherlog_group_name
orlog_destination
must be set.use 'log_destination' argument instead
- max
Aggregation IntegerInterval The maximum interval of time during which a flow of packets is captured and aggregated into a flow log record. Valid Values:
60
seconds (1 minute) or600
seconds (10 minutes). Default:600
. Whentransit_gateway_id
ortransit_gateway_attachment_id
is specified,max_aggregation_interval
must be 60 seconds (1 minute).- subnet
Id String Subnet ID to attach to
- Map<String,String>
Key-value map of resource tags. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.- Map<String,String>
A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.- traffic
Type String The type of traffic to capture. Valid values:
ACCEPT
,REJECT
,ALL
.- transit
Gateway StringAttachment Id Transit Gateway Attachment ID to attach to
- transit
Gateway StringId Transit Gateway ID to attach to
- vpc
Id String VPC ID to attach to
- arn string
The ARN of the Flow Log.
- deliver
Cross stringAccount Role ARN of the IAM role that allows Amazon EC2 to publish flow logs across accounts.
- destination
Options FlowLog Destination Options Args Describes the destination options for a flow log. More details below.
- eni
Id string Elastic Network Interface ID to attach to
- iam
Role stringArn The ARN for the IAM role that's used to post flow logs to a CloudWatch Logs log group
- log
Destination string The ARN of the logging destination. Either
log_destination
orlog_group_name
must be set.- log
Destination stringType The type of the logging destination. Valid values:
cloud-watch-logs
,s3
,kinesis-data-firehose
. Default:cloud-watch-logs
.- log
Format string The fields to include in the flow log record, in the order in which they should appear.
- log
Group stringName Deprecated: Use
log_destination
instead. The name of the CloudWatch log group. Eitherlog_group_name
orlog_destination
must be set.use 'log_destination' argument instead
- max
Aggregation numberInterval The maximum interval of time during which a flow of packets is captured and aggregated into a flow log record. Valid Values:
60
seconds (1 minute) or600
seconds (10 minutes). Default:600
. Whentransit_gateway_id
ortransit_gateway_attachment_id
is specified,max_aggregation_interval
must be 60 seconds (1 minute).- subnet
Id string Subnet ID to attach to
- {[key: string]: string}
Key-value map of resource tags. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.- {[key: string]: string}
A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.- traffic
Type string The type of traffic to capture. Valid values:
ACCEPT
,REJECT
,ALL
.- transit
Gateway stringAttachment Id Transit Gateway Attachment ID to attach to
- transit
Gateway stringId Transit Gateway ID to attach to
- vpc
Id string VPC ID to attach to
- arn str
The ARN of the Flow Log.
- deliver_
cross_ straccount_ role ARN of the IAM role that allows Amazon EC2 to publish flow logs across accounts.
- destination_
options FlowLog Destination Options Args Describes the destination options for a flow log. More details below.
- eni_
id str Elastic Network Interface ID to attach to
- iam_
role_ strarn The ARN for the IAM role that's used to post flow logs to a CloudWatch Logs log group
- log_
destination str The ARN of the logging destination. Either
log_destination
orlog_group_name
must be set.- log_
destination_ strtype The type of the logging destination. Valid values:
cloud-watch-logs
,s3
,kinesis-data-firehose
. Default:cloud-watch-logs
.- log_
format str The fields to include in the flow log record, in the order in which they should appear.
- log_
group_ strname Deprecated: Use
log_destination
instead. The name of the CloudWatch log group. Eitherlog_group_name
orlog_destination
must be set.use 'log_destination' argument instead
- max_
aggregation_ intinterval The maximum interval of time during which a flow of packets is captured and aggregated into a flow log record. Valid Values:
60
seconds (1 minute) or600
seconds (10 minutes). Default:600
. Whentransit_gateway_id
ortransit_gateway_attachment_id
is specified,max_aggregation_interval
must be 60 seconds (1 minute).- subnet_
id str Subnet ID to attach to
- Mapping[str, str]
Key-value map of resource tags. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.- Mapping[str, str]
A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.- traffic_
type str The type of traffic to capture. Valid values:
ACCEPT
,REJECT
,ALL
.- transit_
gateway_ strattachment_ id Transit Gateway Attachment ID to attach to
- transit_
gateway_ strid Transit Gateway ID to attach to
- vpc_
id str VPC ID to attach to
- arn String
The ARN of the Flow Log.
- deliver
Cross StringAccount Role ARN of the IAM role that allows Amazon EC2 to publish flow logs across accounts.
- destination
Options Property Map Describes the destination options for a flow log. More details below.
- eni
Id String Elastic Network Interface ID to attach to
- iam
Role StringArn The ARN for the IAM role that's used to post flow logs to a CloudWatch Logs log group
- log
Destination String The ARN of the logging destination. Either
log_destination
orlog_group_name
must be set.- log
Destination StringType The type of the logging destination. Valid values:
cloud-watch-logs
,s3
,kinesis-data-firehose
. Default:cloud-watch-logs
.- log
Format String The fields to include in the flow log record, in the order in which they should appear.
- log
Group StringName Deprecated: Use
log_destination
instead. The name of the CloudWatch log group. Eitherlog_group_name
orlog_destination
must be set.use 'log_destination' argument instead
- max
Aggregation NumberInterval The maximum interval of time during which a flow of packets is captured and aggregated into a flow log record. Valid Values:
60
seconds (1 minute) or600
seconds (10 minutes). Default:600
. Whentransit_gateway_id
ortransit_gateway_attachment_id
is specified,max_aggregation_interval
must be 60 seconds (1 minute).- subnet
Id String Subnet ID to attach to
- Map<String>
Key-value map of resource tags. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.- Map<String>
A map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.- traffic
Type String The type of traffic to capture. Valid values:
ACCEPT
,REJECT
,ALL
.- transit
Gateway StringAttachment Id Transit Gateway Attachment ID to attach to
- transit
Gateway StringId Transit Gateway ID to attach to
- vpc
Id String VPC ID to attach to
Supporting Types
FlowLogDestinationOptions
- File
Format string The format for the flow log. Default value:
plain-text
. Valid values:plain-text
,parquet
.- Hive
Compatible boolPartitions Indicates whether to use Hive-compatible prefixes for flow logs stored in Amazon S3. Default value:
false
.- Per
Hour boolPartition Indicates whether to partition the flow log per hour. This reduces the cost and response time for queries. Default value:
false
.
- File
Format string The format for the flow log. Default value:
plain-text
. Valid values:plain-text
,parquet
.- Hive
Compatible boolPartitions Indicates whether to use Hive-compatible prefixes for flow logs stored in Amazon S3. Default value:
false
.- Per
Hour boolPartition Indicates whether to partition the flow log per hour. This reduces the cost and response time for queries. Default value:
false
.
- file
Format String The format for the flow log. Default value:
plain-text
. Valid values:plain-text
,parquet
.- hive
Compatible BooleanPartitions Indicates whether to use Hive-compatible prefixes for flow logs stored in Amazon S3. Default value:
false
.- per
Hour BooleanPartition Indicates whether to partition the flow log per hour. This reduces the cost and response time for queries. Default value:
false
.
- file
Format string The format for the flow log. Default value:
plain-text
. Valid values:plain-text
,parquet
.- hive
Compatible booleanPartitions Indicates whether to use Hive-compatible prefixes for flow logs stored in Amazon S3. Default value:
false
.- per
Hour booleanPartition Indicates whether to partition the flow log per hour. This reduces the cost and response time for queries. Default value:
false
.
- file_
format str The format for the flow log. Default value:
plain-text
. Valid values:plain-text
,parquet
.- hive_
compatible_ boolpartitions Indicates whether to use Hive-compatible prefixes for flow logs stored in Amazon S3. Default value:
false
.- per_
hour_ boolpartition Indicates whether to partition the flow log per hour. This reduces the cost and response time for queries. Default value:
false
.
- file
Format String The format for the flow log. Default value:
plain-text
. Valid values:plain-text
,parquet
.- hive
Compatible BooleanPartitions Indicates whether to use Hive-compatible prefixes for flow logs stored in Amazon S3. Default value:
false
.- per
Hour BooleanPartition Indicates whether to partition the flow log per hour. This reduces the cost and response time for queries. Default value:
false
.
Import
Flow Logs can be imported using the id
, e.g.,
$ pulumi import aws:ec2/flowLog:FlowLog test_flow_log fl-1a2b3c4d
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
aws
Terraform Provider.