Try AWS Native preview for resources not in the classic version.
aws.ec2.NetworkInsightsPath
Explore with Pulumi AI
Try AWS Native preview for resources not in the classic version.
Provides a Network Insights Path resource. Part of the “Reachability Analyzer” service in the AWS VPC console.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const test = new aws.ec2.NetworkInsightsPath("test", {
source: source.id,
destination: destination.id,
protocol: "tcp",
});
import pulumi
import pulumi_aws as aws
test = aws.ec2.NetworkInsightsPath("test",
source=source["id"],
destination=destination["id"],
protocol="tcp")
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/ec2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ec2.NewNetworkInsightsPath(ctx, "test", &ec2.NetworkInsightsPathArgs{
Source: pulumi.Any(source.Id),
Destination: pulumi.Any(destination.Id),
Protocol: pulumi.String("tcp"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var test = new Aws.Ec2.NetworkInsightsPath("test", new()
{
Source = source.Id,
Destination = destination.Id,
Protocol = "tcp",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.ec2.NetworkInsightsPath;
import com.pulumi.aws.ec2.NetworkInsightsPathArgs;
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 test = new NetworkInsightsPath("test", NetworkInsightsPathArgs.builder()
.source(source.id())
.destination(destination.id())
.protocol("tcp")
.build());
}
}
resources:
test:
type: aws:ec2:NetworkInsightsPath
properties:
source: ${source.id}
destination: ${destination.id}
protocol: tcp
Create NetworkInsightsPath Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new NetworkInsightsPath(name: string, args: NetworkInsightsPathArgs, opts?: CustomResourceOptions);
@overload
def NetworkInsightsPath(resource_name: str,
args: NetworkInsightsPathArgs,
opts: Optional[ResourceOptions] = None)
@overload
def NetworkInsightsPath(resource_name: str,
opts: Optional[ResourceOptions] = None,
protocol: Optional[str] = None,
source: Optional[str] = None,
destination: Optional[str] = None,
destination_ip: Optional[str] = None,
destination_port: Optional[int] = None,
source_ip: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None)
func NewNetworkInsightsPath(ctx *Context, name string, args NetworkInsightsPathArgs, opts ...ResourceOption) (*NetworkInsightsPath, error)
public NetworkInsightsPath(string name, NetworkInsightsPathArgs args, CustomResourceOptions? opts = null)
public NetworkInsightsPath(String name, NetworkInsightsPathArgs args)
public NetworkInsightsPath(String name, NetworkInsightsPathArgs args, CustomResourceOptions options)
type: aws:ec2:NetworkInsightsPath
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args NetworkInsightsPathArgs
- 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 NetworkInsightsPathArgs
- 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 NetworkInsightsPathArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args NetworkInsightsPathArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args NetworkInsightsPathArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var networkInsightsPathResource = new Aws.Ec2.NetworkInsightsPath("networkInsightsPathResource", new()
{
Protocol = "string",
Source = "string",
Destination = "string",
DestinationIp = "string",
DestinationPort = 0,
SourceIp = "string",
Tags =
{
{ "string", "string" },
},
});
example, err := ec2.NewNetworkInsightsPath(ctx, "networkInsightsPathResource", &ec2.NetworkInsightsPathArgs{
Protocol: pulumi.String("string"),
Source: pulumi.String("string"),
Destination: pulumi.String("string"),
DestinationIp: pulumi.String("string"),
DestinationPort: pulumi.Int(0),
SourceIp: pulumi.String("string"),
Tags: pulumi.StringMap{
"string": pulumi.String("string"),
},
})
var networkInsightsPathResource = new NetworkInsightsPath("networkInsightsPathResource", NetworkInsightsPathArgs.builder()
.protocol("string")
.source("string")
.destination("string")
.destinationIp("string")
.destinationPort(0)
.sourceIp("string")
.tags(Map.of("string", "string"))
.build());
network_insights_path_resource = aws.ec2.NetworkInsightsPath("networkInsightsPathResource",
protocol="string",
source="string",
destination="string",
destination_ip="string",
destination_port=0,
source_ip="string",
tags={
"string": "string",
})
const networkInsightsPathResource = new aws.ec2.NetworkInsightsPath("networkInsightsPathResource", {
protocol: "string",
source: "string",
destination: "string",
destinationIp: "string",
destinationPort: 0,
sourceIp: "string",
tags: {
string: "string",
},
});
type: aws:ec2:NetworkInsightsPath
properties:
destination: string
destinationIp: string
destinationPort: 0
protocol: string
source: string
sourceIp: string
tags:
string: string
NetworkInsightsPath 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 NetworkInsightsPath resource accepts the following input properties:
- Protocol string
Protocol to use for analysis. Valid options are
tcp
orudp
.The following arguments are optional:
- Source string
- ID or ARN of the resource which is the source of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- Destination string
- ID or ARN of the resource which is the destination of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- Destination
Ip string - IP address of the destination resource.
- Destination
Port int - Destination port to analyze access to.
- Source
Ip string - IP address of the source resource.
- Dictionary<string, string>
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- Protocol string
Protocol to use for analysis. Valid options are
tcp
orudp
.The following arguments are optional:
- Source string
- ID or ARN of the resource which is the source of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- Destination string
- ID or ARN of the resource which is the destination of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- Destination
Ip string - IP address of the destination resource.
- Destination
Port int - Destination port to analyze access to.
- Source
Ip string - IP address of the source resource.
- map[string]string
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- protocol String
Protocol to use for analysis. Valid options are
tcp
orudp
.The following arguments are optional:
- source String
- ID or ARN of the resource which is the source of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- destination String
- ID or ARN of the resource which is the destination of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- destination
Ip String - IP address of the destination resource.
- destination
Port Integer - Destination port to analyze access to.
- source
Ip String - IP address of the source resource.
- Map<String,String>
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- protocol string
Protocol to use for analysis. Valid options are
tcp
orudp
.The following arguments are optional:
- source string
- ID or ARN of the resource which is the source of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- destination string
- ID or ARN of the resource which is the destination of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- destination
Ip string - IP address of the destination resource.
- destination
Port number - Destination port to analyze access to.
- source
Ip string - IP address of the source resource.
- {[key: string]: string}
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- protocol str
Protocol to use for analysis. Valid options are
tcp
orudp
.The following arguments are optional:
- source str
- ID or ARN of the resource which is the source of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- destination str
- ID or ARN of the resource which is the destination of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- destination_
ip str - IP address of the destination resource.
- destination_
port int - Destination port to analyze access to.
- source_
ip str - IP address of the source resource.
- Mapping[str, str]
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
- protocol String
Protocol to use for analysis. Valid options are
tcp
orudp
.The following arguments are optional:
- source String
- ID or ARN of the resource which is the source of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- destination String
- ID or ARN of the resource which is the destination of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- destination
Ip String - IP address of the destination resource.
- destination
Port Number - Destination port to analyze access to.
- source
Ip String - IP address of the source resource.
- Map<String>
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Outputs
All input properties are implicitly available as output properties. Additionally, the NetworkInsightsPath resource produces the following output properties:
- Arn string
- ARN of the Network Insights Path.
- Destination
Arn string - ARN of the destination.
- Id string
- The provider-assigned unique ID for this managed resource.
- Source
Arn string - ARN of the source.
- Dictionary<string, string>
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- Arn string
- ARN of the Network Insights Path.
- Destination
Arn string - ARN of the destination.
- Id string
- The provider-assigned unique ID for this managed resource.
- Source
Arn string - ARN of the source.
- map[string]string
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- arn String
- ARN of the Network Insights Path.
- destination
Arn String - ARN of the destination.
- id String
- The provider-assigned unique ID for this managed resource.
- source
Arn String - ARN of the source.
- Map<String,String>
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- arn string
- ARN of the Network Insights Path.
- destination
Arn string - ARN of the destination.
- id string
- The provider-assigned unique ID for this managed resource.
- source
Arn string - ARN of the source.
- {[key: string]: string}
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- arn str
- ARN of the Network Insights Path.
- destination_
arn str - ARN of the destination.
- id str
- The provider-assigned unique ID for this managed resource.
- source_
arn str - ARN of the source.
- Mapping[str, str]
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- arn String
- ARN of the Network Insights Path.
- destination
Arn String - ARN of the destination.
- id String
- The provider-assigned unique ID for this managed resource.
- source
Arn String - ARN of the source.
- Map<String>
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
Look up Existing NetworkInsightsPath Resource
Get an existing NetworkInsightsPath 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?: NetworkInsightsPathState, opts?: CustomResourceOptions): NetworkInsightsPath
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
arn: Optional[str] = None,
destination: Optional[str] = None,
destination_arn: Optional[str] = None,
destination_ip: Optional[str] = None,
destination_port: Optional[int] = None,
protocol: Optional[str] = None,
source: Optional[str] = None,
source_arn: Optional[str] = None,
source_ip: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None,
tags_all: Optional[Mapping[str, str]] = None) -> NetworkInsightsPath
func GetNetworkInsightsPath(ctx *Context, name string, id IDInput, state *NetworkInsightsPathState, opts ...ResourceOption) (*NetworkInsightsPath, error)
public static NetworkInsightsPath Get(string name, Input<string> id, NetworkInsightsPathState? state, CustomResourceOptions? opts = null)
public static NetworkInsightsPath get(String name, Output<String> id, NetworkInsightsPathState 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
- ARN of the Network Insights Path.
- Destination string
- ID or ARN of the resource which is the destination of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- Destination
Arn string - ARN of the destination.
- Destination
Ip string - IP address of the destination resource.
- Destination
Port int - Destination port to analyze access to.
- Protocol string
Protocol to use for analysis. Valid options are
tcp
orudp
.The following arguments are optional:
- Source string
- ID or ARN of the resource which is the source of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- Source
Arn string - ARN of the source.
- Source
Ip string - IP address of the source resource.
- Dictionary<string, string>
- Map of tags to assign to the resource. 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>
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- Arn string
- ARN of the Network Insights Path.
- Destination string
- ID or ARN of the resource which is the destination of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- Destination
Arn string - ARN of the destination.
- Destination
Ip string - IP address of the destination resource.
- Destination
Port int - Destination port to analyze access to.
- Protocol string
Protocol to use for analysis. Valid options are
tcp
orudp
.The following arguments are optional:
- Source string
- ID or ARN of the resource which is the source of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- Source
Arn string - ARN of the source.
- Source
Ip string - IP address of the source resource.
- map[string]string
- Map of tags to assign to the resource. 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
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- arn String
- ARN of the Network Insights Path.
- destination String
- ID or ARN of the resource which is the destination of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- destination
Arn String - ARN of the destination.
- destination
Ip String - IP address of the destination resource.
- destination
Port Integer - Destination port to analyze access to.
- protocol String
Protocol to use for analysis. Valid options are
tcp
orudp
.The following arguments are optional:
- source String
- ID or ARN of the resource which is the source of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- source
Arn String - ARN of the source.
- source
Ip String - IP address of the source resource.
- Map<String,String>
- Map of tags to assign to the resource. 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>
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- arn string
- ARN of the Network Insights Path.
- destination string
- ID or ARN of the resource which is the destination of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- destination
Arn string - ARN of the destination.
- destination
Ip string - IP address of the destination resource.
- destination
Port number - Destination port to analyze access to.
- protocol string
Protocol to use for analysis. Valid options are
tcp
orudp
.The following arguments are optional:
- source string
- ID or ARN of the resource which is the source of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- source
Arn string - ARN of the source.
- source
Ip string - IP address of the source resource.
- {[key: string]: string}
- Map of tags to assign to the resource. 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}
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- arn str
- ARN of the Network Insights Path.
- destination str
- ID or ARN of the resource which is the destination of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- destination_
arn str - ARN of the destination.
- destination_
ip str - IP address of the destination resource.
- destination_
port int - Destination port to analyze access to.
- protocol str
Protocol to use for analysis. Valid options are
tcp
orudp
.The following arguments are optional:
- source str
- ID or ARN of the resource which is the source of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- source_
arn str - ARN of the source.
- source_
ip str - IP address of the source resource.
- Mapping[str, str]
- Map of tags to assign to the resource. 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]
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
- arn String
- ARN of the Network Insights Path.
- destination String
- ID or ARN of the resource which is the destination of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- destination
Arn String - ARN of the destination.
- destination
Ip String - IP address of the destination resource.
- destination
Port Number - Destination port to analyze access to.
- protocol String
Protocol to use for analysis. Valid options are
tcp
orudp
.The following arguments are optional:
- source String
- ID or ARN of the resource which is the source of the path. Can be an Instance, Internet Gateway, Network Interface, Transit Gateway, VPC Endpoint, VPC Peering Connection or VPN Gateway. If the resource is in another account, you must specify an ARN.
- source
Arn String - ARN of the source.
- source
Ip String - IP address of the source resource.
- Map<String>
- Map of tags to assign to the resource. If configured with a provider
default_tags
configuration block present, tags with matching keys will overwrite those defined at the provider-level. - Map<String>
- Map of tags assigned to the resource, including those inherited from the provider
default_tags
configuration block.
Import
Using pulumi import
, import Network Insights Paths using the id
. For example:
$ pulumi import aws:ec2/networkInsightsPath:NetworkInsightsPath test nip-00edfba169923aefd
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
aws
Terraform Provider.
Try AWS Native preview for resources not in the classic version.