Class FlowLogOptions
Options to add a flow log to a VPC.
Inheritance
System.Object
FlowLogOptions
Implements
Namespace: Amazon.CDK.AWS.EC2
Assembly: Amazon.CDK.AWS.EC2.dll
Syntax (csharp)
public class FlowLogOptions : Object, IFlowLogOptions
Syntax (vb)
Public Class FlowLogOptions
Inherits Object
Implements IFlowLogOptions
Remarks
ExampleMetadata: infused
Examples
var vpc = new Vpc(this, "Vpc");
vpc.AddFlowLog("FlowLogS3", new FlowLogOptions {
Destination = FlowLogDestination.ToS3()
});
vpc.AddFlowLog("FlowLogCloudWatch", new FlowLogOptions {
TrafficType = FlowLogTrafficType.REJECT
});
Synopsis
Constructors
FlowLogOptions() |
Properties
Destination | Specifies the type of destination to which the flow log data is to be published. |
TrafficType | The type of traffic to log. |
Constructors
FlowLogOptions()
public FlowLogOptions()
Properties
Destination
Specifies the type of destination to which the flow log data is to be published.
public FlowLogDestination Destination { get; set; }
Property Value
Remarks
Flow log data can be published to CloudWatch Logs or Amazon S3
Default: FlowLogDestinationType.toCloudWatchLogs()
TrafficType
The type of traffic to log.
public Nullable<FlowLogTrafficType> TrafficType { get; set; }
Property Value
System.Nullable<FlowLogTrafficType>
Remarks
You can log traffic that the resource accepts or rejects, or all traffic.
Default: ALL