Skip to content
v2.277.0

Experimental

@aws-cdk/aws-mediaconnect-alpha is an experimental (alpha) package: its API may change in any release, without a major version bump.

NetworkConfiguration Class ​

Defines network configuration for a source — either a public network with a CIDR allowlist, or a VPC interface.

Example ​

ts
declare const stack: Stack;

const flow = new Flow(stack, 'MyFlow', {
  source: SourceConfiguration.srtListener({
    flowSourceName: 'live-encoder-source',
    description: 'Live encoder feed',
    port: 5000,
    minLatency: Duration.millis(2000),
    network: NetworkConfiguration.publicNetwork('203.0.113.0/24'),
  }),
});
python
# stack: Stack


flow = Flow(stack, "MyFlow",
    source=SourceConfiguration.srt_listener(
        flow_source_name="live-encoder-source",
        description="Live encoder feed",
        port=5000,
        min_latency=Duration.millis(2000),
        network=NetworkConfiguration.public_network("203.0.113.0/24")
    )
)
java
Stack stack;


Flow flow = Flow.Builder.create(stack, "MyFlow")
        .source(SourceConfiguration.srtListener(SourceSrtListener.builder()
                .flowSourceName("live-encoder-source")
                .description("Live encoder feed")
                .port(5000)
                .minLatency(Duration.millis(2000))
                .network(NetworkConfiguration.publicNetwork("203.0.113.0/24"))
                .build()))
        .build();
csharp
// Install: dotnet add package Amazon.CDK.AWS.MediaConnect.Alpha
Stack stack;


var flow = new Flow(stack, "MyFlow", new FlowProps {
    Source = SourceConfiguration.SrtListener(new SourceSrtListener {
        FlowSourceName = "live-encoder-source",
        Description = "Live encoder feed",
        Port = 5000,
        MinLatency = Duration.Millis(2000),
        Network = NetworkConfiguration.PublicNetwork("203.0.113.0/24")
    })
});
go
// Install: go get github.com/aws/aws-cdk-go/awsmediaconnectalpha/v2
var stack Stack


flow := awsmediaconnectalpha.NewFlow(stack, jsii.String("MyFlow"), &FlowProps{
	Source: awsmediaconnectalpha.SourceConfiguration_SrtListener(&SourceSrtListener{
		FlowSourceName: jsii.String("live-encoder-source"),
		Description: jsii.String("Live encoder feed"),
		Port: jsii.Number(5000),
		MinLatency: awscdk.Duration_Millis(jsii.Number(2000)),
		Network: awsmediaconnectalpha.NetworkConfiguration_PublicNetwork(jsii.String("203.0.113.0/24")),
	}),
})

Properties ​

allowlistCidrmay be undefinedstringallowlist_cidrmay be undefinedstrallowlistCidrmay be undefinedStringAllowlistCidrmay be undefinedstringAllowlistCidrmay be undefined*string#
The CIDR allowlist for public internet sources, or undefined if using VPC.
vpcInterfaceNamemay be undefinedstringvpc_interface_namemay be undefinedstrvpcInterfaceNamemay be undefinedStringVpcInterfaceNamemay be undefinedstringVpcInterfaceNamemay be undefined*string#
The VPC interface name, or undefined if using public internet.

Methods ​

publicNetwork(allowlistCidr: string): NetworkConfiguration // chainable@staticmethod def public_network(allowlist_cidr: str) -> NetworkConfigurationpublic static NetworkConfiguration publicNetwork(String allowlistCidr)public static NetworkConfiguration PublicNetwork(string allowlistCidr)func PublicNetwork(AllowlistCidr *string) NetworkConfigurationstatic#
Use a public network with a CIDR allowlist.
vpc(vpcInterface: VpcInterfaceConfig): NetworkConfiguration // chainable@staticmethod def vpc(vpc_interface: VpcInterfaceConfig) -> NetworkConfigurationpublic static NetworkConfiguration vpc(VpcInterfaceConfig vpcInterface)public static NetworkConfiguration Vpc(VpcInterfaceConfig vpcInterface)func Vpc(VpcInterface VpcInterfaceConfig) NetworkConfigurationstatic#
Use a VPC interface.