1. Packages
  2. AWS
  3. API Docs
  4. vpclattice
  5. Listener
AWS v6.64.0 published on Friday, Dec 6, 2024 by Pulumi

aws.vpclattice.Listener

Explore with Pulumi AI

aws logo
AWS v6.64.0 published on Friday, Dec 6, 2024 by Pulumi

    Resource for managing an AWS VPC Lattice Listener.

    Example Usage

    Fixed response action

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = new aws.vpclattice.Service("example", {name: "example"});
    const exampleListener = new aws.vpclattice.Listener("example", {
        name: "example",
        protocol: "HTTPS",
        serviceIdentifier: example.id,
        defaultAction: {
            fixedResponse: {
                statusCode: 404,
            },
        },
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.vpclattice.Service("example", name="example")
    example_listener = aws.vpclattice.Listener("example",
        name="example",
        protocol="HTTPS",
        service_identifier=example.id,
        default_action={
            "fixed_response": {
                "status_code": 404,
            },
        })
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/vpclattice"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := vpclattice.NewService(ctx, "example", &vpclattice.ServiceArgs{
    			Name: pulumi.String("example"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = vpclattice.NewListener(ctx, "example", &vpclattice.ListenerArgs{
    			Name:              pulumi.String("example"),
    			Protocol:          pulumi.String("HTTPS"),
    			ServiceIdentifier: example.ID(),
    			DefaultAction: &vpclattice.ListenerDefaultActionArgs{
    				FixedResponse: &vpclattice.ListenerDefaultActionFixedResponseArgs{
    					StatusCode: pulumi.Int(404),
    				},
    			},
    		})
    		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 example = new Aws.VpcLattice.Service("example", new()
        {
            Name = "example",
        });
    
        var exampleListener = new Aws.VpcLattice.Listener("example", new()
        {
            Name = "example",
            Protocol = "HTTPS",
            ServiceIdentifier = example.Id,
            DefaultAction = new Aws.VpcLattice.Inputs.ListenerDefaultActionArgs
            {
                FixedResponse = new Aws.VpcLattice.Inputs.ListenerDefaultActionFixedResponseArgs
                {
                    StatusCode = 404,
                },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.vpclattice.Service;
    import com.pulumi.aws.vpclattice.ServiceArgs;
    import com.pulumi.aws.vpclattice.Listener;
    import com.pulumi.aws.vpclattice.ListenerArgs;
    import com.pulumi.aws.vpclattice.inputs.ListenerDefaultActionArgs;
    import com.pulumi.aws.vpclattice.inputs.ListenerDefaultActionFixedResponseArgs;
    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 example = new Service("example", ServiceArgs.builder()
                .name("example")
                .build());
    
            var exampleListener = new Listener("exampleListener", ListenerArgs.builder()
                .name("example")
                .protocol("HTTPS")
                .serviceIdentifier(example.id())
                .defaultAction(ListenerDefaultActionArgs.builder()
                    .fixedResponse(ListenerDefaultActionFixedResponseArgs.builder()
                        .statusCode(404)
                        .build())
                    .build())
                .build());
    
        }
    }
    
    resources:
      example:
        type: aws:vpclattice:Service
        properties:
          name: example
      exampleListener:
        type: aws:vpclattice:Listener
        name: example
        properties:
          name: example
          protocol: HTTPS
          serviceIdentifier: ${example.id}
          defaultAction:
            fixedResponse:
              statusCode: 404
    

    Forward action

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = new aws.vpclattice.Service("example", {name: "example"});
    const exampleTargetGroup = new aws.vpclattice.TargetGroup("example", {
        name: "example-target-group-1",
        type: "INSTANCE",
        config: {
            port: 80,
            protocol: "HTTP",
            vpcIdentifier: exampleAwsVpc.id,
        },
    });
    const exampleListener = new aws.vpclattice.Listener("example", {
        name: "example",
        protocol: "HTTP",
        serviceIdentifier: example.id,
        defaultAction: {
            forwards: [{
                targetGroups: [{
                    targetGroupIdentifier: exampleTargetGroup.id,
                }],
            }],
        },
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.vpclattice.Service("example", name="example")
    example_target_group = aws.vpclattice.TargetGroup("example",
        name="example-target-group-1",
        type="INSTANCE",
        config={
            "port": 80,
            "protocol": "HTTP",
            "vpc_identifier": example_aws_vpc["id"],
        })
    example_listener = aws.vpclattice.Listener("example",
        name="example",
        protocol="HTTP",
        service_identifier=example.id,
        default_action={
            "forwards": [{
                "target_groups": [{
                    "target_group_identifier": example_target_group.id,
                }],
            }],
        })
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/vpclattice"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := vpclattice.NewService(ctx, "example", &vpclattice.ServiceArgs{
    			Name: pulumi.String("example"),
    		})
    		if err != nil {
    			return err
    		}
    		exampleTargetGroup, err := vpclattice.NewTargetGroup(ctx, "example", &vpclattice.TargetGroupArgs{
    			Name: pulumi.String("example-target-group-1"),
    			Type: pulumi.String("INSTANCE"),
    			Config: &vpclattice.TargetGroupConfigArgs{
    				Port:          pulumi.Int(80),
    				Protocol:      pulumi.String("HTTP"),
    				VpcIdentifier: pulumi.Any(exampleAwsVpc.Id),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = vpclattice.NewListener(ctx, "example", &vpclattice.ListenerArgs{
    			Name:              pulumi.String("example"),
    			Protocol:          pulumi.String("HTTP"),
    			ServiceIdentifier: example.ID(),
    			DefaultAction: &vpclattice.ListenerDefaultActionArgs{
    				Forwards: vpclattice.ListenerDefaultActionForwardArray{
    					&vpclattice.ListenerDefaultActionForwardArgs{
    						TargetGroups: vpclattice.ListenerDefaultActionForwardTargetGroupArray{
    							&vpclattice.ListenerDefaultActionForwardTargetGroupArgs{
    								TargetGroupIdentifier: exampleTargetGroup.ID(),
    							},
    						},
    					},
    				},
    			},
    		})
    		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 example = new Aws.VpcLattice.Service("example", new()
        {
            Name = "example",
        });
    
        var exampleTargetGroup = new Aws.VpcLattice.TargetGroup("example", new()
        {
            Name = "example-target-group-1",
            Type = "INSTANCE",
            Config = new Aws.VpcLattice.Inputs.TargetGroupConfigArgs
            {
                Port = 80,
                Protocol = "HTTP",
                VpcIdentifier = exampleAwsVpc.Id,
            },
        });
    
        var exampleListener = new Aws.VpcLattice.Listener("example", new()
        {
            Name = "example",
            Protocol = "HTTP",
            ServiceIdentifier = example.Id,
            DefaultAction = new Aws.VpcLattice.Inputs.ListenerDefaultActionArgs
            {
                Forwards = new[]
                {
                    new Aws.VpcLattice.Inputs.ListenerDefaultActionForwardArgs
                    {
                        TargetGroups = new[]
                        {
                            new Aws.VpcLattice.Inputs.ListenerDefaultActionForwardTargetGroupArgs
                            {
                                TargetGroupIdentifier = exampleTargetGroup.Id,
                            },
                        },
                    },
                },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.vpclattice.Service;
    import com.pulumi.aws.vpclattice.ServiceArgs;
    import com.pulumi.aws.vpclattice.TargetGroup;
    import com.pulumi.aws.vpclattice.TargetGroupArgs;
    import com.pulumi.aws.vpclattice.inputs.TargetGroupConfigArgs;
    import com.pulumi.aws.vpclattice.Listener;
    import com.pulumi.aws.vpclattice.ListenerArgs;
    import com.pulumi.aws.vpclattice.inputs.ListenerDefaultActionArgs;
    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 example = new Service("example", ServiceArgs.builder()
                .name("example")
                .build());
    
            var exampleTargetGroup = new TargetGroup("exampleTargetGroup", TargetGroupArgs.builder()
                .name("example-target-group-1")
                .type("INSTANCE")
                .config(TargetGroupConfigArgs.builder()
                    .port(80)
                    .protocol("HTTP")
                    .vpcIdentifier(exampleAwsVpc.id())
                    .build())
                .build());
    
            var exampleListener = new Listener("exampleListener", ListenerArgs.builder()
                .name("example")
                .protocol("HTTP")
                .serviceIdentifier(example.id())
                .defaultAction(ListenerDefaultActionArgs.builder()
                    .forwards(ListenerDefaultActionForwardArgs.builder()
                        .targetGroups(ListenerDefaultActionForwardTargetGroupArgs.builder()
                            .targetGroupIdentifier(exampleTargetGroup.id())
                            .build())
                        .build())
                    .build())
                .build());
    
        }
    }
    
    resources:
      example:
        type: aws:vpclattice:Service
        properties:
          name: example
      exampleTargetGroup:
        type: aws:vpclattice:TargetGroup
        name: example
        properties:
          name: example-target-group-1
          type: INSTANCE
          config:
            port: 80
            protocol: HTTP
            vpcIdentifier: ${exampleAwsVpc.id}
      exampleListener:
        type: aws:vpclattice:Listener
        name: example
        properties:
          name: example
          protocol: HTTP
          serviceIdentifier: ${example.id}
          defaultAction:
            forwards:
              - targetGroups:
                  - targetGroupIdentifier: ${exampleTargetGroup.id}
    

    Forward action with weighted target groups

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = new aws.vpclattice.Service("example", {name: "example"});
    const example1 = new aws.vpclattice.TargetGroup("example1", {
        name: "example-target-group-1",
        type: "INSTANCE",
        config: {
            port: 80,
            protocol: "HTTP",
            vpcIdentifier: exampleAwsVpc.id,
        },
    });
    const example2 = new aws.vpclattice.TargetGroup("example2", {
        name: "example-target-group-2",
        type: "INSTANCE",
        config: {
            port: 8080,
            protocol: "HTTP",
            vpcIdentifier: exampleAwsVpc.id,
        },
    });
    const exampleListener = new aws.vpclattice.Listener("example", {
        name: "example",
        protocol: "HTTP",
        serviceIdentifier: example.id,
        defaultAction: {
            forwards: [{
                targetGroups: [
                    {
                        targetGroupIdentifier: example1.id,
                        weight: 80,
                    },
                    {
                        targetGroupIdentifier: example2.id,
                        weight: 20,
                    },
                ],
            }],
        },
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.vpclattice.Service("example", name="example")
    example1 = aws.vpclattice.TargetGroup("example1",
        name="example-target-group-1",
        type="INSTANCE",
        config={
            "port": 80,
            "protocol": "HTTP",
            "vpc_identifier": example_aws_vpc["id"],
        })
    example2 = aws.vpclattice.TargetGroup("example2",
        name="example-target-group-2",
        type="INSTANCE",
        config={
            "port": 8080,
            "protocol": "HTTP",
            "vpc_identifier": example_aws_vpc["id"],
        })
    example_listener = aws.vpclattice.Listener("example",
        name="example",
        protocol="HTTP",
        service_identifier=example.id,
        default_action={
            "forwards": [{
                "target_groups": [
                    {
                        "target_group_identifier": example1.id,
                        "weight": 80,
                    },
                    {
                        "target_group_identifier": example2.id,
                        "weight": 20,
                    },
                ],
            }],
        })
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/vpclattice"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := vpclattice.NewService(ctx, "example", &vpclattice.ServiceArgs{
    			Name: pulumi.String("example"),
    		})
    		if err != nil {
    			return err
    		}
    		example1, err := vpclattice.NewTargetGroup(ctx, "example1", &vpclattice.TargetGroupArgs{
    			Name: pulumi.String("example-target-group-1"),
    			Type: pulumi.String("INSTANCE"),
    			Config: &vpclattice.TargetGroupConfigArgs{
    				Port:          pulumi.Int(80),
    				Protocol:      pulumi.String("HTTP"),
    				VpcIdentifier: pulumi.Any(exampleAwsVpc.Id),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		example2, err := vpclattice.NewTargetGroup(ctx, "example2", &vpclattice.TargetGroupArgs{
    			Name: pulumi.String("example-target-group-2"),
    			Type: pulumi.String("INSTANCE"),
    			Config: &vpclattice.TargetGroupConfigArgs{
    				Port:          pulumi.Int(8080),
    				Protocol:      pulumi.String("HTTP"),
    				VpcIdentifier: pulumi.Any(exampleAwsVpc.Id),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = vpclattice.NewListener(ctx, "example", &vpclattice.ListenerArgs{
    			Name:              pulumi.String("example"),
    			Protocol:          pulumi.String("HTTP"),
    			ServiceIdentifier: example.ID(),
    			DefaultAction: &vpclattice.ListenerDefaultActionArgs{
    				Forwards: vpclattice.ListenerDefaultActionForwardArray{
    					&vpclattice.ListenerDefaultActionForwardArgs{
    						TargetGroups: vpclattice.ListenerDefaultActionForwardTargetGroupArray{
    							&vpclattice.ListenerDefaultActionForwardTargetGroupArgs{
    								TargetGroupIdentifier: example1.ID(),
    								Weight:                pulumi.Int(80),
    							},
    							&vpclattice.ListenerDefaultActionForwardTargetGroupArgs{
    								TargetGroupIdentifier: example2.ID(),
    								Weight:                pulumi.Int(20),
    							},
    						},
    					},
    				},
    			},
    		})
    		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 example = new Aws.VpcLattice.Service("example", new()
        {
            Name = "example",
        });
    
        var example1 = new Aws.VpcLattice.TargetGroup("example1", new()
        {
            Name = "example-target-group-1",
            Type = "INSTANCE",
            Config = new Aws.VpcLattice.Inputs.TargetGroupConfigArgs
            {
                Port = 80,
                Protocol = "HTTP",
                VpcIdentifier = exampleAwsVpc.Id,
            },
        });
    
        var example2 = new Aws.VpcLattice.TargetGroup("example2", new()
        {
            Name = "example-target-group-2",
            Type = "INSTANCE",
            Config = new Aws.VpcLattice.Inputs.TargetGroupConfigArgs
            {
                Port = 8080,
                Protocol = "HTTP",
                VpcIdentifier = exampleAwsVpc.Id,
            },
        });
    
        var exampleListener = new Aws.VpcLattice.Listener("example", new()
        {
            Name = "example",
            Protocol = "HTTP",
            ServiceIdentifier = example.Id,
            DefaultAction = new Aws.VpcLattice.Inputs.ListenerDefaultActionArgs
            {
                Forwards = new[]
                {
                    new Aws.VpcLattice.Inputs.ListenerDefaultActionForwardArgs
                    {
                        TargetGroups = new[]
                        {
                            new Aws.VpcLattice.Inputs.ListenerDefaultActionForwardTargetGroupArgs
                            {
                                TargetGroupIdentifier = example1.Id,
                                Weight = 80,
                            },
                            new Aws.VpcLattice.Inputs.ListenerDefaultActionForwardTargetGroupArgs
                            {
                                TargetGroupIdentifier = example2.Id,
                                Weight = 20,
                            },
                        },
                    },
                },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.vpclattice.Service;
    import com.pulumi.aws.vpclattice.ServiceArgs;
    import com.pulumi.aws.vpclattice.TargetGroup;
    import com.pulumi.aws.vpclattice.TargetGroupArgs;
    import com.pulumi.aws.vpclattice.inputs.TargetGroupConfigArgs;
    import com.pulumi.aws.vpclattice.Listener;
    import com.pulumi.aws.vpclattice.ListenerArgs;
    import com.pulumi.aws.vpclattice.inputs.ListenerDefaultActionArgs;
    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 example = new Service("example", ServiceArgs.builder()
                .name("example")
                .build());
    
            var example1 = new TargetGroup("example1", TargetGroupArgs.builder()
                .name("example-target-group-1")
                .type("INSTANCE")
                .config(TargetGroupConfigArgs.builder()
                    .port(80)
                    .protocol("HTTP")
                    .vpcIdentifier(exampleAwsVpc.id())
                    .build())
                .build());
    
            var example2 = new TargetGroup("example2", TargetGroupArgs.builder()
                .name("example-target-group-2")
                .type("INSTANCE")
                .config(TargetGroupConfigArgs.builder()
                    .port(8080)
                    .protocol("HTTP")
                    .vpcIdentifier(exampleAwsVpc.id())
                    .build())
                .build());
    
            var exampleListener = new Listener("exampleListener", ListenerArgs.builder()
                .name("example")
                .protocol("HTTP")
                .serviceIdentifier(example.id())
                .defaultAction(ListenerDefaultActionArgs.builder()
                    .forwards(ListenerDefaultActionForwardArgs.builder()
                        .targetGroups(                    
                            ListenerDefaultActionForwardTargetGroupArgs.builder()
                                .targetGroupIdentifier(example1.id())
                                .weight(80)
                                .build(),
                            ListenerDefaultActionForwardTargetGroupArgs.builder()
                                .targetGroupIdentifier(example2.id())
                                .weight(20)
                                .build())
                        .build())
                    .build())
                .build());
    
        }
    }
    
    resources:
      example:
        type: aws:vpclattice:Service
        properties:
          name: example
      example1:
        type: aws:vpclattice:TargetGroup
        properties:
          name: example-target-group-1
          type: INSTANCE
          config:
            port: 80
            protocol: HTTP
            vpcIdentifier: ${exampleAwsVpc.id}
      example2:
        type: aws:vpclattice:TargetGroup
        properties:
          name: example-target-group-2
          type: INSTANCE
          config:
            port: 8080
            protocol: HTTP
            vpcIdentifier: ${exampleAwsVpc.id}
      exampleListener:
        type: aws:vpclattice:Listener
        name: example
        properties:
          name: example
          protocol: HTTP
          serviceIdentifier: ${example.id}
          defaultAction:
            forwards:
              - targetGroups:
                  - targetGroupIdentifier: ${example1.id}
                    weight: 80
                  - targetGroupIdentifier: ${example2.id}
                    weight: 20
    

    Create Listener Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Listener(name: string, args: ListenerArgs, opts?: CustomResourceOptions);
    @overload
    def Listener(resource_name: str,
                 args: ListenerArgs,
                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def Listener(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 default_action: Optional[ListenerDefaultActionArgs] = None,
                 protocol: Optional[str] = None,
                 name: Optional[str] = None,
                 port: Optional[int] = None,
                 service_arn: Optional[str] = None,
                 service_identifier: Optional[str] = None,
                 tags: Optional[Mapping[str, str]] = None)
    func NewListener(ctx *Context, name string, args ListenerArgs, opts ...ResourceOption) (*Listener, error)
    public Listener(string name, ListenerArgs args, CustomResourceOptions? opts = null)
    public Listener(String name, ListenerArgs args)
    public Listener(String name, ListenerArgs args, CustomResourceOptions options)
    
    type: aws:vpclattice:Listener
    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 ListenerArgs
    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 ListenerArgs
    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 ListenerArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ListenerArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ListenerArgs
    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 examplelistenerResourceResourceFromVpclatticelistener = new Aws.VpcLattice.Listener("examplelistenerResourceResourceFromVpclatticelistener", new()
    {
        DefaultAction = new Aws.VpcLattice.Inputs.ListenerDefaultActionArgs
        {
            FixedResponse = new Aws.VpcLattice.Inputs.ListenerDefaultActionFixedResponseArgs
            {
                StatusCode = 0,
            },
            Forwards = new[]
            {
                new Aws.VpcLattice.Inputs.ListenerDefaultActionForwardArgs
                {
                    TargetGroups = new[]
                    {
                        new Aws.VpcLattice.Inputs.ListenerDefaultActionForwardTargetGroupArgs
                        {
                            TargetGroupIdentifier = "string",
                            Weight = 0,
                        },
                    },
                },
            },
        },
        Protocol = "string",
        Name = "string",
        Port = 0,
        ServiceArn = "string",
        ServiceIdentifier = "string",
        Tags = 
        {
            { "string", "string" },
        },
    });
    
    example, err := vpclattice.NewListener(ctx, "examplelistenerResourceResourceFromVpclatticelistener", &vpclattice.ListenerArgs{
    	DefaultAction: &vpclattice.ListenerDefaultActionArgs{
    		FixedResponse: &vpclattice.ListenerDefaultActionFixedResponseArgs{
    			StatusCode: pulumi.Int(0),
    		},
    		Forwards: vpclattice.ListenerDefaultActionForwardArray{
    			&vpclattice.ListenerDefaultActionForwardArgs{
    				TargetGroups: vpclattice.ListenerDefaultActionForwardTargetGroupArray{
    					&vpclattice.ListenerDefaultActionForwardTargetGroupArgs{
    						TargetGroupIdentifier: pulumi.String("string"),
    						Weight:                pulumi.Int(0),
    					},
    				},
    			},
    		},
    	},
    	Protocol:          pulumi.String("string"),
    	Name:              pulumi.String("string"),
    	Port:              pulumi.Int(0),
    	ServiceArn:        pulumi.String("string"),
    	ServiceIdentifier: pulumi.String("string"),
    	Tags: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    })
    
    var examplelistenerResourceResourceFromVpclatticelistener = new Listener("examplelistenerResourceResourceFromVpclatticelistener", ListenerArgs.builder()
        .defaultAction(ListenerDefaultActionArgs.builder()
            .fixedResponse(ListenerDefaultActionFixedResponseArgs.builder()
                .statusCode(0)
                .build())
            .forwards(ListenerDefaultActionForwardArgs.builder()
                .targetGroups(ListenerDefaultActionForwardTargetGroupArgs.builder()
                    .targetGroupIdentifier("string")
                    .weight(0)
                    .build())
                .build())
            .build())
        .protocol("string")
        .name("string")
        .port(0)
        .serviceArn("string")
        .serviceIdentifier("string")
        .tags(Map.of("string", "string"))
        .build());
    
    examplelistener_resource_resource_from_vpclatticelistener = aws.vpclattice.Listener("examplelistenerResourceResourceFromVpclatticelistener",
        default_action={
            "fixed_response": {
                "status_code": 0,
            },
            "forwards": [{
                "target_groups": [{
                    "target_group_identifier": "string",
                    "weight": 0,
                }],
            }],
        },
        protocol="string",
        name="string",
        port=0,
        service_arn="string",
        service_identifier="string",
        tags={
            "string": "string",
        })
    
    const examplelistenerResourceResourceFromVpclatticelistener = new aws.vpclattice.Listener("examplelistenerResourceResourceFromVpclatticelistener", {
        defaultAction: {
            fixedResponse: {
                statusCode: 0,
            },
            forwards: [{
                targetGroups: [{
                    targetGroupIdentifier: "string",
                    weight: 0,
                }],
            }],
        },
        protocol: "string",
        name: "string",
        port: 0,
        serviceArn: "string",
        serviceIdentifier: "string",
        tags: {
            string: "string",
        },
    });
    
    type: aws:vpclattice:Listener
    properties:
        defaultAction:
            fixedResponse:
                statusCode: 0
            forwards:
                - targetGroups:
                    - targetGroupIdentifier: string
                      weight: 0
        name: string
        port: 0
        protocol: string
        serviceArn: string
        serviceIdentifier: string
        tags:
            string: string
    

    Listener Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The Listener resource accepts the following input properties:

    DefaultAction ListenerDefaultAction
    Default action block for the default listener rule. Default action blocks are defined below.
    Protocol string
    Protocol for the listener. Supported values are HTTP, HTTPS or TLS_PASSTHROUGH
    Name string
    Name of the listener. A listener name must be unique within a service. Valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.
    Port int
    Listener port. You can specify a value from 1 to 65535. If port is not specified and protocol is HTTP, the value will default to 80. If port is not specified and protocol is HTTPS, the value will default to 443.
    ServiceArn string
    Amazon Resource Name (ARN) of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.
    ServiceIdentifier string

    ID of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.

    NOTE: You must specify one of the following arguments: service_arn or service_identifier.

    Tags Dictionary<string, string>
    A 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.
    DefaultAction ListenerDefaultActionArgs
    Default action block for the default listener rule. Default action blocks are defined below.
    Protocol string
    Protocol for the listener. Supported values are HTTP, HTTPS or TLS_PASSTHROUGH
    Name string
    Name of the listener. A listener name must be unique within a service. Valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.
    Port int
    Listener port. You can specify a value from 1 to 65535. If port is not specified and protocol is HTTP, the value will default to 80. If port is not specified and protocol is HTTPS, the value will default to 443.
    ServiceArn string
    Amazon Resource Name (ARN) of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.
    ServiceIdentifier string

    ID of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.

    NOTE: You must specify one of the following arguments: service_arn or service_identifier.

    Tags map[string]string
    A 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.
    defaultAction ListenerDefaultAction
    Default action block for the default listener rule. Default action blocks are defined below.
    protocol String
    Protocol for the listener. Supported values are HTTP, HTTPS or TLS_PASSTHROUGH
    name String
    Name of the listener. A listener name must be unique within a service. Valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.
    port Integer
    Listener port. You can specify a value from 1 to 65535. If port is not specified and protocol is HTTP, the value will default to 80. If port is not specified and protocol is HTTPS, the value will default to 443.
    serviceArn String
    Amazon Resource Name (ARN) of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.
    serviceIdentifier String

    ID of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.

    NOTE: You must specify one of the following arguments: service_arn or service_identifier.

    tags Map<String,String>
    A 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.
    defaultAction ListenerDefaultAction
    Default action block for the default listener rule. Default action blocks are defined below.
    protocol string
    Protocol for the listener. Supported values are HTTP, HTTPS or TLS_PASSTHROUGH
    name string
    Name of the listener. A listener name must be unique within a service. Valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.
    port number
    Listener port. You can specify a value from 1 to 65535. If port is not specified and protocol is HTTP, the value will default to 80. If port is not specified and protocol is HTTPS, the value will default to 443.
    serviceArn string
    Amazon Resource Name (ARN) of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.
    serviceIdentifier string

    ID of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.

    NOTE: You must specify one of the following arguments: service_arn or service_identifier.

    tags {[key: string]: string}
    A 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.
    default_action ListenerDefaultActionArgs
    Default action block for the default listener rule. Default action blocks are defined below.
    protocol str
    Protocol for the listener. Supported values are HTTP, HTTPS or TLS_PASSTHROUGH
    name str
    Name of the listener. A listener name must be unique within a service. Valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.
    port int
    Listener port. You can specify a value from 1 to 65535. If port is not specified and protocol is HTTP, the value will default to 80. If port is not specified and protocol is HTTPS, the value will default to 443.
    service_arn str
    Amazon Resource Name (ARN) of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.
    service_identifier str

    ID of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.

    NOTE: You must specify one of the following arguments: service_arn or service_identifier.

    tags Mapping[str, str]
    A 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.
    defaultAction Property Map
    Default action block for the default listener rule. Default action blocks are defined below.
    protocol String
    Protocol for the listener. Supported values are HTTP, HTTPS or TLS_PASSTHROUGH
    name String
    Name of the listener. A listener name must be unique within a service. Valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.
    port Number
    Listener port. You can specify a value from 1 to 65535. If port is not specified and protocol is HTTP, the value will default to 80. If port is not specified and protocol is HTTPS, the value will default to 443.
    serviceArn String
    Amazon Resource Name (ARN) of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.
    serviceIdentifier String

    ID of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.

    NOTE: You must specify one of the following arguments: service_arn or service_identifier.

    tags Map<String>
    A 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 Listener resource produces the following output properties:

    Arn string
    ARN of the listener.
    CreatedAt string
    Date and time that the listener was created, specified in ISO-8601 format.
    Id string
    The provider-assigned unique ID for this managed resource.
    LastUpdatedAt string
    ListenerId string
    Standalone ID of the listener, e.g. listener-0a1b2c3d4e5f6g.
    TagsAll Dictionary<string, string>

    Deprecated: Please use tags instead.

    Arn string
    ARN of the listener.
    CreatedAt string
    Date and time that the listener was created, specified in ISO-8601 format.
    Id string
    The provider-assigned unique ID for this managed resource.
    LastUpdatedAt string
    ListenerId string
    Standalone ID of the listener, e.g. listener-0a1b2c3d4e5f6g.
    TagsAll map[string]string

    Deprecated: Please use tags instead.

    arn String
    ARN of the listener.
    createdAt String
    Date and time that the listener was created, specified in ISO-8601 format.
    id String
    The provider-assigned unique ID for this managed resource.
    lastUpdatedAt String
    listenerId String
    Standalone ID of the listener, e.g. listener-0a1b2c3d4e5f6g.
    tagsAll Map<String,String>

    Deprecated: Please use tags instead.

    arn string
    ARN of the listener.
    createdAt string
    Date and time that the listener was created, specified in ISO-8601 format.
    id string
    The provider-assigned unique ID for this managed resource.
    lastUpdatedAt string
    listenerId string
    Standalone ID of the listener, e.g. listener-0a1b2c3d4e5f6g.
    tagsAll {[key: string]: string}

    Deprecated: Please use tags instead.

    arn str
    ARN of the listener.
    created_at str
    Date and time that the listener was created, specified in ISO-8601 format.
    id str
    The provider-assigned unique ID for this managed resource.
    last_updated_at str
    listener_id str
    Standalone ID of the listener, e.g. listener-0a1b2c3d4e5f6g.
    tags_all Mapping[str, str]

    Deprecated: Please use tags instead.

    arn String
    ARN of the listener.
    createdAt String
    Date and time that the listener was created, specified in ISO-8601 format.
    id String
    The provider-assigned unique ID for this managed resource.
    lastUpdatedAt String
    listenerId String
    Standalone ID of the listener, e.g. listener-0a1b2c3d4e5f6g.
    tagsAll Map<String>

    Deprecated: Please use tags instead.

    Look up Existing Listener Resource

    Get an existing Listener 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?: ListenerState, opts?: CustomResourceOptions): Listener
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            arn: Optional[str] = None,
            created_at: Optional[str] = None,
            default_action: Optional[ListenerDefaultActionArgs] = None,
            last_updated_at: Optional[str] = None,
            listener_id: Optional[str] = None,
            name: Optional[str] = None,
            port: Optional[int] = None,
            protocol: Optional[str] = None,
            service_arn: Optional[str] = None,
            service_identifier: Optional[str] = None,
            tags: Optional[Mapping[str, str]] = None,
            tags_all: Optional[Mapping[str, str]] = None) -> Listener
    func GetListener(ctx *Context, name string, id IDInput, state *ListenerState, opts ...ResourceOption) (*Listener, error)
    public static Listener Get(string name, Input<string> id, ListenerState? state, CustomResourceOptions? opts = null)
    public static Listener get(String name, Output<String> id, ListenerState 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.
    The following state arguments are supported:
    Arn string
    ARN of the listener.
    CreatedAt string
    Date and time that the listener was created, specified in ISO-8601 format.
    DefaultAction ListenerDefaultAction
    Default action block for the default listener rule. Default action blocks are defined below.
    LastUpdatedAt string
    ListenerId string
    Standalone ID of the listener, e.g. listener-0a1b2c3d4e5f6g.
    Name string
    Name of the listener. A listener name must be unique within a service. Valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.
    Port int
    Listener port. You can specify a value from 1 to 65535. If port is not specified and protocol is HTTP, the value will default to 80. If port is not specified and protocol is HTTPS, the value will default to 443.
    Protocol string
    Protocol for the listener. Supported values are HTTP, HTTPS or TLS_PASSTHROUGH
    ServiceArn string
    Amazon Resource Name (ARN) of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.
    ServiceIdentifier string

    ID of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.

    NOTE: You must specify one of the following arguments: service_arn or service_identifier.

    Tags Dictionary<string, string>
    A 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.
    TagsAll Dictionary<string, string>

    Deprecated: Please use tags instead.

    Arn string
    ARN of the listener.
    CreatedAt string
    Date and time that the listener was created, specified in ISO-8601 format.
    DefaultAction ListenerDefaultActionArgs
    Default action block for the default listener rule. Default action blocks are defined below.
    LastUpdatedAt string
    ListenerId string
    Standalone ID of the listener, e.g. listener-0a1b2c3d4e5f6g.
    Name string
    Name of the listener. A listener name must be unique within a service. Valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.
    Port int
    Listener port. You can specify a value from 1 to 65535. If port is not specified and protocol is HTTP, the value will default to 80. If port is not specified and protocol is HTTPS, the value will default to 443.
    Protocol string
    Protocol for the listener. Supported values are HTTP, HTTPS or TLS_PASSTHROUGH
    ServiceArn string
    Amazon Resource Name (ARN) of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.
    ServiceIdentifier string

    ID of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.

    NOTE: You must specify one of the following arguments: service_arn or service_identifier.

    Tags map[string]string
    A 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.
    TagsAll map[string]string

    Deprecated: Please use tags instead.

    arn String
    ARN of the listener.
    createdAt String
    Date and time that the listener was created, specified in ISO-8601 format.
    defaultAction ListenerDefaultAction
    Default action block for the default listener rule. Default action blocks are defined below.
    lastUpdatedAt String
    listenerId String
    Standalone ID of the listener, e.g. listener-0a1b2c3d4e5f6g.
    name String
    Name of the listener. A listener name must be unique within a service. Valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.
    port Integer
    Listener port. You can specify a value from 1 to 65535. If port is not specified and protocol is HTTP, the value will default to 80. If port is not specified and protocol is HTTPS, the value will default to 443.
    protocol String
    Protocol for the listener. Supported values are HTTP, HTTPS or TLS_PASSTHROUGH
    serviceArn String
    Amazon Resource Name (ARN) of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.
    serviceIdentifier String

    ID of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.

    NOTE: You must specify one of the following arguments: service_arn or service_identifier.

    tags Map<String,String>
    A 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.
    tagsAll Map<String,String>

    Deprecated: Please use tags instead.

    arn string
    ARN of the listener.
    createdAt string
    Date and time that the listener was created, specified in ISO-8601 format.
    defaultAction ListenerDefaultAction
    Default action block for the default listener rule. Default action blocks are defined below.
    lastUpdatedAt string
    listenerId string
    Standalone ID of the listener, e.g. listener-0a1b2c3d4e5f6g.
    name string
    Name of the listener. A listener name must be unique within a service. Valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.
    port number
    Listener port. You can specify a value from 1 to 65535. If port is not specified and protocol is HTTP, the value will default to 80. If port is not specified and protocol is HTTPS, the value will default to 443.
    protocol string
    Protocol for the listener. Supported values are HTTP, HTTPS or TLS_PASSTHROUGH
    serviceArn string
    Amazon Resource Name (ARN) of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.
    serviceIdentifier string

    ID of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.

    NOTE: You must specify one of the following arguments: service_arn or service_identifier.

    tags {[key: string]: string}
    A 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.
    tagsAll {[key: string]: string}

    Deprecated: Please use tags instead.

    arn str
    ARN of the listener.
    created_at str
    Date and time that the listener was created, specified in ISO-8601 format.
    default_action ListenerDefaultActionArgs
    Default action block for the default listener rule. Default action blocks are defined below.
    last_updated_at str
    listener_id str
    Standalone ID of the listener, e.g. listener-0a1b2c3d4e5f6g.
    name str
    Name of the listener. A listener name must be unique within a service. Valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.
    port int
    Listener port. You can specify a value from 1 to 65535. If port is not specified and protocol is HTTP, the value will default to 80. If port is not specified and protocol is HTTPS, the value will default to 443.
    protocol str
    Protocol for the listener. Supported values are HTTP, HTTPS or TLS_PASSTHROUGH
    service_arn str
    Amazon Resource Name (ARN) of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.
    service_identifier str

    ID of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.

    NOTE: You must specify one of the following arguments: service_arn or service_identifier.

    tags Mapping[str, str]
    A 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.
    tags_all Mapping[str, str]

    Deprecated: Please use tags instead.

    arn String
    ARN of the listener.
    createdAt String
    Date and time that the listener was created, specified in ISO-8601 format.
    defaultAction Property Map
    Default action block for the default listener rule. Default action blocks are defined below.
    lastUpdatedAt String
    listenerId String
    Standalone ID of the listener, e.g. listener-0a1b2c3d4e5f6g.
    name String
    Name of the listener. A listener name must be unique within a service. Valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.
    port Number
    Listener port. You can specify a value from 1 to 65535. If port is not specified and protocol is HTTP, the value will default to 80. If port is not specified and protocol is HTTPS, the value will default to 443.
    protocol String
    Protocol for the listener. Supported values are HTTP, HTTPS or TLS_PASSTHROUGH
    serviceArn String
    Amazon Resource Name (ARN) of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.
    serviceIdentifier String

    ID of the VPC Lattice service. You must include either the service_arn or service_identifier arguments.

    NOTE: You must specify one of the following arguments: service_arn or service_identifier.

    tags Map<String>
    A 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.
    tagsAll Map<String>

    Deprecated: Please use tags instead.

    Supporting Types

    ListenerDefaultAction, ListenerDefaultActionArgs

    FixedResponse ListenerDefaultActionFixedResponse
    Forwards List<ListenerDefaultActionForward>

    Route requests to one or more target groups. See Forward blocks below.

    NOTE: You must specify exactly one of the following argument blocks: fixed_response or forward.

    FixedResponse ListenerDefaultActionFixedResponse
    Forwards []ListenerDefaultActionForward

    Route requests to one or more target groups. See Forward blocks below.

    NOTE: You must specify exactly one of the following argument blocks: fixed_response or forward.

    fixedResponse ListenerDefaultActionFixedResponse
    forwards List<ListenerDefaultActionForward>

    Route requests to one or more target groups. See Forward blocks below.

    NOTE: You must specify exactly one of the following argument blocks: fixed_response or forward.

    fixedResponse ListenerDefaultActionFixedResponse
    forwards ListenerDefaultActionForward[]

    Route requests to one or more target groups. See Forward blocks below.

    NOTE: You must specify exactly one of the following argument blocks: fixed_response or forward.

    fixed_response ListenerDefaultActionFixedResponse
    forwards Sequence[ListenerDefaultActionForward]

    Route requests to one or more target groups. See Forward blocks below.

    NOTE: You must specify exactly one of the following argument blocks: fixed_response or forward.

    fixedResponse Property Map
    forwards List<Property Map>

    Route requests to one or more target groups. See Forward blocks below.

    NOTE: You must specify exactly one of the following argument blocks: fixed_response or forward.

    ListenerDefaultActionFixedResponse, ListenerDefaultActionFixedResponseArgs

    StatusCode int
    Custom HTTP status code to return, e.g. a 404 response code. See Listeners in the AWS documentation for a list of supported codes.
    StatusCode int
    Custom HTTP status code to return, e.g. a 404 response code. See Listeners in the AWS documentation for a list of supported codes.
    statusCode Integer
    Custom HTTP status code to return, e.g. a 404 response code. See Listeners in the AWS documentation for a list of supported codes.
    statusCode number
    Custom HTTP status code to return, e.g. a 404 response code. See Listeners in the AWS documentation for a list of supported codes.
    status_code int
    Custom HTTP status code to return, e.g. a 404 response code. See Listeners in the AWS documentation for a list of supported codes.
    statusCode Number
    Custom HTTP status code to return, e.g. a 404 response code. See Listeners in the AWS documentation for a list of supported codes.

    ListenerDefaultActionForward, ListenerDefaultActionForwardArgs

    targetGroups List<Property Map>
    One or more target group blocks.

    ListenerDefaultActionForwardTargetGroup, ListenerDefaultActionForwardTargetGroupArgs

    TargetGroupIdentifier string
    ID or Amazon Resource Name (ARN) of the target group.
    Weight int
    Determines how requests are distributed to the target group. Only required if you specify multiple target groups for a forward action. For example, if you specify two target groups, one with a weight of 10 and the other with a weight of 20, the target group with a weight of 20 receives twice as many requests as the other target group. See Listener rules in the AWS documentation for additional examples. Default: 100.
    TargetGroupIdentifier string
    ID or Amazon Resource Name (ARN) of the target group.
    Weight int
    Determines how requests are distributed to the target group. Only required if you specify multiple target groups for a forward action. For example, if you specify two target groups, one with a weight of 10 and the other with a weight of 20, the target group with a weight of 20 receives twice as many requests as the other target group. See Listener rules in the AWS documentation for additional examples. Default: 100.
    targetGroupIdentifier String
    ID or Amazon Resource Name (ARN) of the target group.
    weight Integer
    Determines how requests are distributed to the target group. Only required if you specify multiple target groups for a forward action. For example, if you specify two target groups, one with a weight of 10 and the other with a weight of 20, the target group with a weight of 20 receives twice as many requests as the other target group. See Listener rules in the AWS documentation for additional examples. Default: 100.
    targetGroupIdentifier string
    ID or Amazon Resource Name (ARN) of the target group.
    weight number
    Determines how requests are distributed to the target group. Only required if you specify multiple target groups for a forward action. For example, if you specify two target groups, one with a weight of 10 and the other with a weight of 20, the target group with a weight of 20 receives twice as many requests as the other target group. See Listener rules in the AWS documentation for additional examples. Default: 100.
    target_group_identifier str
    ID or Amazon Resource Name (ARN) of the target group.
    weight int
    Determines how requests are distributed to the target group. Only required if you specify multiple target groups for a forward action. For example, if you specify two target groups, one with a weight of 10 and the other with a weight of 20, the target group with a weight of 20 receives twice as many requests as the other target group. See Listener rules in the AWS documentation for additional examples. Default: 100.
    targetGroupIdentifier String
    ID or Amazon Resource Name (ARN) of the target group.
    weight Number
    Determines how requests are distributed to the target group. Only required if you specify multiple target groups for a forward action. For example, if you specify two target groups, one with a weight of 10 and the other with a weight of 20, the target group with a weight of 20 receives twice as many requests as the other target group. See Listener rules in the AWS documentation for additional examples. Default: 100.

    Import

    Using pulumi import, import VPC Lattice Listener using the listener_id of the listener and the id of the VPC Lattice service combined with a / character. For example:

    $ pulumi import aws:vpclattice/listener:Listener example svc-1a2b3c4d/listener-987654321
    

    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.
    aws logo
    AWS v6.64.0 published on Friday, Dec 6, 2024 by Pulumi