1. Packages
  2. Alibaba Cloud Provider
  3. API Docs
  4. nlb
  5. LoadBalancer
Alibaba Cloud v3.76.0 published on Tuesday, Apr 8, 2025 by Pulumi

alicloud.nlb.LoadBalancer

Explore with Pulumi AI

Provides a Network Load Balancer (NLB) Load Balancer resource.

For information about Network Load Balancer (NLB) Load Balancer and how to use it, see What is Load Balancer.

NOTE: Available since v1.191.0.

Example Usage

Basic Usage

import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const config = new pulumi.Config();
const name = config.get("name") || "tf-example";
const _default = alicloud.resourcemanager.getResourceGroups({});
const defaultGetZones = alicloud.nlb.getZones({});
const defaultNetwork = new alicloud.vpc.Network("default", {
    vpcName: name,
    cidrBlock: "10.4.0.0/16",
});
const defaultSwitch = new alicloud.vpc.Switch("default", {
    vswitchName: name,
    cidrBlock: "10.4.0.0/24",
    vpcId: defaultNetwork.id,
    zoneId: defaultGetZones.then(defaultGetZones => defaultGetZones.zones?.[0]?.id),
});
const default1 = new alicloud.vpc.Switch("default1", {
    vswitchName: name,
    cidrBlock: "10.4.1.0/24",
    vpcId: defaultNetwork.id,
    zoneId: defaultGetZones.then(defaultGetZones => defaultGetZones.zones?.[1]?.id),
});
const defaultLoadBalancer = new alicloud.nlb.LoadBalancer("default", {
    loadBalancerName: name,
    resourceGroupId: _default.then(_default => _default.ids?.[0]),
    loadBalancerType: "Network",
    addressType: "Internet",
    addressIpVersion: "Ipv4",
    vpcId: defaultNetwork.id,
    tags: {
        Created: "TF",
        For: "example",
    },
    zoneMappings: [
        {
            vswitchId: defaultSwitch.id,
            zoneId: defaultGetZones.then(defaultGetZones => defaultGetZones.zones?.[0]?.id),
        },
        {
            vswitchId: default1.id,
            zoneId: defaultGetZones.then(defaultGetZones => defaultGetZones.zones?.[1]?.id),
        },
    ],
});
Copy
import pulumi
import pulumi_alicloud as alicloud

config = pulumi.Config()
name = config.get("name")
if name is None:
    name = "tf-example"
default = alicloud.resourcemanager.get_resource_groups()
default_get_zones = alicloud.nlb.get_zones()
default_network = alicloud.vpc.Network("default",
    vpc_name=name,
    cidr_block="10.4.0.0/16")
default_switch = alicloud.vpc.Switch("default",
    vswitch_name=name,
    cidr_block="10.4.0.0/24",
    vpc_id=default_network.id,
    zone_id=default_get_zones.zones[0].id)
default1 = alicloud.vpc.Switch("default1",
    vswitch_name=name,
    cidr_block="10.4.1.0/24",
    vpc_id=default_network.id,
    zone_id=default_get_zones.zones[1].id)
default_load_balancer = alicloud.nlb.LoadBalancer("default",
    load_balancer_name=name,
    resource_group_id=default.ids[0],
    load_balancer_type="Network",
    address_type="Internet",
    address_ip_version="Ipv4",
    vpc_id=default_network.id,
    tags={
        "Created": "TF",
        "For": "example",
    },
    zone_mappings=[
        {
            "vswitch_id": default_switch.id,
            "zone_id": default_get_zones.zones[0].id,
        },
        {
            "vswitch_id": default1.id,
            "zone_id": default_get_zones.zones[1].id,
        },
    ])
Copy
package main

import (
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/nlb"
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/resourcemanager"
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/vpc"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		cfg := config.New(ctx, "")
		name := "tf-example"
		if param := cfg.Get("name"); param != "" {
			name = param
		}
		_default, err := resourcemanager.GetResourceGroups(ctx, &resourcemanager.GetResourceGroupsArgs{}, nil)
		if err != nil {
			return err
		}
		defaultGetZones, err := nlb.GetZones(ctx, &nlb.GetZonesArgs{}, nil)
		if err != nil {
			return err
		}
		defaultNetwork, err := vpc.NewNetwork(ctx, "default", &vpc.NetworkArgs{
			VpcName:   pulumi.String(name),
			CidrBlock: pulumi.String("10.4.0.0/16"),
		})
		if err != nil {
			return err
		}
		defaultSwitch, err := vpc.NewSwitch(ctx, "default", &vpc.SwitchArgs{
			VswitchName: pulumi.String(name),
			CidrBlock:   pulumi.String("10.4.0.0/24"),
			VpcId:       defaultNetwork.ID(),
			ZoneId:      pulumi.String(defaultGetZones.Zones[0].Id),
		})
		if err != nil {
			return err
		}
		default1, err := vpc.NewSwitch(ctx, "default1", &vpc.SwitchArgs{
			VswitchName: pulumi.String(name),
			CidrBlock:   pulumi.String("10.4.1.0/24"),
			VpcId:       defaultNetwork.ID(),
			ZoneId:      pulumi.String(defaultGetZones.Zones[1].Id),
		})
		if err != nil {
			return err
		}
		_, err = nlb.NewLoadBalancer(ctx, "default", &nlb.LoadBalancerArgs{
			LoadBalancerName: pulumi.String(name),
			ResourceGroupId:  pulumi.String(_default.Ids[0]),
			LoadBalancerType: pulumi.String("Network"),
			AddressType:      pulumi.String("Internet"),
			AddressIpVersion: pulumi.String("Ipv4"),
			VpcId:            defaultNetwork.ID(),
			Tags: pulumi.StringMap{
				"Created": pulumi.String("TF"),
				"For":     pulumi.String("example"),
			},
			ZoneMappings: nlb.LoadBalancerZoneMappingArray{
				&nlb.LoadBalancerZoneMappingArgs{
					VswitchId: defaultSwitch.ID(),
					ZoneId:    pulumi.String(defaultGetZones.Zones[0].Id),
				},
				&nlb.LoadBalancerZoneMappingArgs{
					VswitchId: default1.ID(),
					ZoneId:    pulumi.String(defaultGetZones.Zones[1].Id),
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;

return await Deployment.RunAsync(() => 
{
    var config = new Config();
    var name = config.Get("name") ?? "tf-example";
    var @default = AliCloud.ResourceManager.GetResourceGroups.Invoke();

    var defaultGetZones = AliCloud.Nlb.GetZones.Invoke();

    var defaultNetwork = new AliCloud.Vpc.Network("default", new()
    {
        VpcName = name,
        CidrBlock = "10.4.0.0/16",
    });

    var defaultSwitch = new AliCloud.Vpc.Switch("default", new()
    {
        VswitchName = name,
        CidrBlock = "10.4.0.0/24",
        VpcId = defaultNetwork.Id,
        ZoneId = defaultGetZones.Apply(getZonesResult => getZonesResult.Zones[0]?.Id),
    });

    var default1 = new AliCloud.Vpc.Switch("default1", new()
    {
        VswitchName = name,
        CidrBlock = "10.4.1.0/24",
        VpcId = defaultNetwork.Id,
        ZoneId = defaultGetZones.Apply(getZonesResult => getZonesResult.Zones[1]?.Id),
    });

    var defaultLoadBalancer = new AliCloud.Nlb.LoadBalancer("default", new()
    {
        LoadBalancerName = name,
        ResourceGroupId = @default.Apply(@default => @default.Apply(getResourceGroupsResult => getResourceGroupsResult.Ids[0])),
        LoadBalancerType = "Network",
        AddressType = "Internet",
        AddressIpVersion = "Ipv4",
        VpcId = defaultNetwork.Id,
        Tags = 
        {
            { "Created", "TF" },
            { "For", "example" },
        },
        ZoneMappings = new[]
        {
            new AliCloud.Nlb.Inputs.LoadBalancerZoneMappingArgs
            {
                VswitchId = defaultSwitch.Id,
                ZoneId = defaultGetZones.Apply(getZonesResult => getZonesResult.Zones[0]?.Id),
            },
            new AliCloud.Nlb.Inputs.LoadBalancerZoneMappingArgs
            {
                VswitchId = default1.Id,
                ZoneId = defaultGetZones.Apply(getZonesResult => getZonesResult.Zones[1]?.Id),
            },
        },
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.resourcemanager.ResourcemanagerFunctions;
import com.pulumi.alicloud.resourcemanager.inputs.GetResourceGroupsArgs;
import com.pulumi.alicloud.nlb.NlbFunctions;
import com.pulumi.alicloud.nlb.inputs.GetZonesArgs;
import com.pulumi.alicloud.vpc.Network;
import com.pulumi.alicloud.vpc.NetworkArgs;
import com.pulumi.alicloud.vpc.Switch;
import com.pulumi.alicloud.vpc.SwitchArgs;
import com.pulumi.alicloud.nlb.LoadBalancer;
import com.pulumi.alicloud.nlb.LoadBalancerArgs;
import com.pulumi.alicloud.nlb.inputs.LoadBalancerZoneMappingArgs;
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) {
        final var config = ctx.config();
        final var name = config.get("name").orElse("tf-example");
        final var default = ResourcemanagerFunctions.getResourceGroups();

        final var defaultGetZones = NlbFunctions.getZones();

        var defaultNetwork = new Network("defaultNetwork", NetworkArgs.builder()
            .vpcName(name)
            .cidrBlock("10.4.0.0/16")
            .build());

        var defaultSwitch = new Switch("defaultSwitch", SwitchArgs.builder()
            .vswitchName(name)
            .cidrBlock("10.4.0.0/24")
            .vpcId(defaultNetwork.id())
            .zoneId(defaultGetZones.applyValue(getZonesResult -> getZonesResult.zones()[0].id()))
            .build());

        var default1 = new Switch("default1", SwitchArgs.builder()
            .vswitchName(name)
            .cidrBlock("10.4.1.0/24")
            .vpcId(defaultNetwork.id())
            .zoneId(defaultGetZones.applyValue(getZonesResult -> getZonesResult.zones()[1].id()))
            .build());

        var defaultLoadBalancer = new LoadBalancer("defaultLoadBalancer", LoadBalancerArgs.builder()
            .loadBalancerName(name)
            .resourceGroupId(default_.ids()[0])
            .loadBalancerType("Network")
            .addressType("Internet")
            .addressIpVersion("Ipv4")
            .vpcId(defaultNetwork.id())
            .tags(Map.ofEntries(
                Map.entry("Created", "TF"),
                Map.entry("For", "example")
            ))
            .zoneMappings(            
                LoadBalancerZoneMappingArgs.builder()
                    .vswitchId(defaultSwitch.id())
                    .zoneId(defaultGetZones.applyValue(getZonesResult -> getZonesResult.zones()[0].id()))
                    .build(),
                LoadBalancerZoneMappingArgs.builder()
                    .vswitchId(default1.id())
                    .zoneId(defaultGetZones.applyValue(getZonesResult -> getZonesResult.zones()[1].id()))
                    .build())
            .build());

    }
}
Copy
configuration:
  name:
    type: string
    default: tf-example
resources:
  defaultNetwork:
    type: alicloud:vpc:Network
    name: default
    properties:
      vpcName: ${name}
      cidrBlock: 10.4.0.0/16
  defaultSwitch:
    type: alicloud:vpc:Switch
    name: default
    properties:
      vswitchName: ${name}
      cidrBlock: 10.4.0.0/24
      vpcId: ${defaultNetwork.id}
      zoneId: ${defaultGetZones.zones[0].id}
  default1:
    type: alicloud:vpc:Switch
    properties:
      vswitchName: ${name}
      cidrBlock: 10.4.1.0/24
      vpcId: ${defaultNetwork.id}
      zoneId: ${defaultGetZones.zones[1].id}
  defaultLoadBalancer:
    type: alicloud:nlb:LoadBalancer
    name: default
    properties:
      loadBalancerName: ${name}
      resourceGroupId: ${default.ids[0]}
      loadBalancerType: Network
      addressType: Internet
      addressIpVersion: Ipv4
      vpcId: ${defaultNetwork.id}
      tags:
        Created: TF
        For: example
      zoneMappings:
        - vswitchId: ${defaultSwitch.id}
          zoneId: ${defaultGetZones.zones[0].id}
        - vswitchId: ${default1.id}
          zoneId: ${defaultGetZones.zones[1].id}
variables:
  default:
    fn::invoke:
      function: alicloud:resourcemanager:getResourceGroups
      arguments: {}
  defaultGetZones:
    fn::invoke:
      function: alicloud:nlb:getZones
      arguments: {}
Copy

DualStack Usage

import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const config = new pulumi.Config();
const name = config.get("name") || "tf-example";
const zone = config.getObject("zone") || [
    "cn-beijing-i",
    "cn-beijing-k",
    "cn-beijing-l",
];
const vpc = new alicloud.vpc.Network("vpc", {
    vpcName: name,
    cidrBlock: "10.2.0.0/16",
    enableIpv6: true,
});
const vsw: alicloud.vpc.Switch[] = [];
for (const range = {value: 0}; range.value < 2; range.value++) {
    vsw.push(new alicloud.vpc.Switch(`vsw-${range.value}`, {
        enableIpv6: true,
        ipv6CidrBlockMask: `1${range.value}`,
        vswitchName: `vsw-${range.value}-for-nlb`,
        vpcId: vpc.id,
        cidrBlock: `10.2.1${range.value}.0/24`,
        zoneId: zone[range.value],
    }));
}
const _default = new alicloud.vpc.Ipv6Gateway("default", {
    ipv6GatewayName: name,
    vpcId: vpc.id,
});
const nlb = new alicloud.nlb.LoadBalancer("nlb", {
    loadBalancerName: name,
    loadBalancerType: "Network",
    addressType: "Intranet",
    addressIpVersion: "DualStack",
    ipv6AddressType: "Internet",
    vpcId: vpc.id,
    crossZoneEnabled: false,
    tags: {
        Created: "TF",
        For: "example",
    },
    zoneMappings: [
        {
            vswitchId: vsw[0].id,
            zoneId: zone[0],
        },
        {
            vswitchId: vsw[1].id,
            zoneId: zone[1],
        },
    ],
}, {
    dependsOn: [_default],
});
Copy
import pulumi
import pulumi_alicloud as alicloud

config = pulumi.Config()
name = config.get("name")
if name is None:
    name = "tf-example"
zone = config.get_object("zone")
if zone is None:
    zone = [
        "cn-beijing-i",
        "cn-beijing-k",
        "cn-beijing-l",
    ]
vpc = alicloud.vpc.Network("vpc",
    vpc_name=name,
    cidr_block="10.2.0.0/16",
    enable_ipv6=True)
vsw = []
for range in [{"value": i} for i in range(0, 2)]:
    vsw.append(alicloud.vpc.Switch(f"vsw-{range['value']}",
        enable_ipv6=True,
        ipv6_cidr_block_mask=f"1{range['value']}",
        vswitch_name=f"vsw-{range['value']}-for-nlb",
        vpc_id=vpc.id,
        cidr_block=f"10.2.1{range['value']}.0/24",
        zone_id=zone[range["value"]]))
default = alicloud.vpc.Ipv6Gateway("default",
    ipv6_gateway_name=name,
    vpc_id=vpc.id)
nlb = alicloud.nlb.LoadBalancer("nlb",
    load_balancer_name=name,
    load_balancer_type="Network",
    address_type="Intranet",
    address_ip_version="DualStack",
    ipv6_address_type="Internet",
    vpc_id=vpc.id,
    cross_zone_enabled=False,
    tags={
        "Created": "TF",
        "For": "example",
    },
    zone_mappings=[
        {
            "vswitch_id": vsw[0].id,
            "zone_id": zone[0],
        },
        {
            "vswitch_id": vsw[1].id,
            "zone_id": zone[1],
        },
    ],
    opts = pulumi.ResourceOptions(depends_on=[default]))
Copy
package main

import (
	"fmt"

	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/nlb"
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/vpc"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		cfg := config.New(ctx, "")
		name := "tf-example"
		if param := cfg.Get("name"); param != "" {
			name = param
		}
		zone := []string{
			"cn-beijing-i",
			"cn-beijing-k",
			"cn-beijing-l",
		}
		if param := cfg.GetObject("zone"); param != nil {
			zone = param
		}
		vpc, err := vpc.NewNetwork(ctx, "vpc", &vpc.NetworkArgs{
			VpcName:    pulumi.String(name),
			CidrBlock:  pulumi.String("10.2.0.0/16"),
			EnableIpv6: pulumi.Bool(true),
		})
		if err != nil {
			return err
		}
		var vsw []*vpc.Switch
		for index := 0; index < 2; index++ {
			key0 := index
			val0 := index
			__res, err := vpc.NewSwitch(ctx, fmt.Sprintf("vsw-%v", key0), &vpc.SwitchArgs{
				EnableIpv6:        pulumi.Bool(true),
				Ipv6CidrBlockMask: pulumi.Int(fmt.Sprintf("1%v", val0)),
				VswitchName:       pulumi.Sprintf("vsw-%v-for-nlb", val0),
				VpcId:             vpc.ID(),
				CidrBlock:         pulumi.Sprintf("10.2.1%v.0/24", val0),
				ZoneId:            zone[val0],
			})
			if err != nil {
				return err
			}
			vsw = append(vsw, __res)
		}
		_default, err := vpc.NewIpv6Gateway(ctx, "default", &vpc.Ipv6GatewayArgs{
			Ipv6GatewayName: pulumi.String(name),
			VpcId:           vpc.ID(),
		})
		if err != nil {
			return err
		}
		_, err = nlb.NewLoadBalancer(ctx, "nlb", &nlb.LoadBalancerArgs{
			LoadBalancerName: pulumi.String(name),
			LoadBalancerType: pulumi.String("Network"),
			AddressType:      pulumi.String("Intranet"),
			AddressIpVersion: pulumi.String("DualStack"),
			Ipv6AddressType:  pulumi.String("Internet"),
			VpcId:            vpc.ID(),
			CrossZoneEnabled: pulumi.Bool(false),
			Tags: pulumi.StringMap{
				"Created": pulumi.String("TF"),
				"For":     pulumi.String("example"),
			},
			ZoneMappings: nlb.LoadBalancerZoneMappingArray{
				&nlb.LoadBalancerZoneMappingArgs{
					VswitchId: vsw[0].ID(),
					ZoneId:    pulumi.Any(zone[0]),
				},
				&nlb.LoadBalancerZoneMappingArgs{
					VswitchId: vsw[1].ID(),
					ZoneId:    pulumi.Any(zone[1]),
				},
			},
		}, pulumi.DependsOn([]pulumi.Resource{
			_default,
		}))
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;

return await Deployment.RunAsync(() => 
{
    var config = new Config();
    var name = config.Get("name") ?? "tf-example";
    var zone = config.GetObject<dynamic>("zone") ?? new[]
    {
        "cn-beijing-i",
        "cn-beijing-k",
        "cn-beijing-l",
    };
    var vpc = new AliCloud.Vpc.Network("vpc", new()
    {
        VpcName = name,
        CidrBlock = "10.2.0.0/16",
        EnableIpv6 = true,
    });

    var vsw = new List<AliCloud.Vpc.Switch>();
    for (var rangeIndex = 0; rangeIndex < 2; rangeIndex++)
    {
        var range = new { Value = rangeIndex };
        vsw.Add(new AliCloud.Vpc.Switch($"vsw-{range.Value}", new()
        {
            EnableIpv6 = true,
            Ipv6CidrBlockMask = $"1{range.Value}",
            VswitchName = $"vsw-{range.Value}-for-nlb",
            VpcId = vpc.Id,
            CidrBlock = $"10.2.1{range.Value}.0/24",
            ZoneId = zone[range.Value],
        }));
    }
    var @default = new AliCloud.Vpc.Ipv6Gateway("default", new()
    {
        Ipv6GatewayName = name,
        VpcId = vpc.Id,
    });

    var nlb = new AliCloud.Nlb.LoadBalancer("nlb", new()
    {
        LoadBalancerName = name,
        LoadBalancerType = "Network",
        AddressType = "Intranet",
        AddressIpVersion = "DualStack",
        Ipv6AddressType = "Internet",
        VpcId = vpc.Id,
        CrossZoneEnabled = false,
        Tags = 
        {
            { "Created", "TF" },
            { "For", "example" },
        },
        ZoneMappings = new[]
        {
            new AliCloud.Nlb.Inputs.LoadBalancerZoneMappingArgs
            {
                VswitchId = vsw[0].Id,
                ZoneId = zone[0],
            },
            new AliCloud.Nlb.Inputs.LoadBalancerZoneMappingArgs
            {
                VswitchId = vsw[1].Id,
                ZoneId = zone[1],
            },
        },
    }, new CustomResourceOptions
    {
        DependsOn =
        {
            @default,
        },
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.vpc.Network;
import com.pulumi.alicloud.vpc.NetworkArgs;
import com.pulumi.alicloud.vpc.Switch;
import com.pulumi.alicloud.vpc.SwitchArgs;
import com.pulumi.alicloud.vpc.Ipv6Gateway;
import com.pulumi.alicloud.vpc.Ipv6GatewayArgs;
import com.pulumi.alicloud.nlb.LoadBalancer;
import com.pulumi.alicloud.nlb.LoadBalancerArgs;
import com.pulumi.alicloud.nlb.inputs.LoadBalancerZoneMappingArgs;
import com.pulumi.codegen.internal.KeyedValue;
import com.pulumi.resources.CustomResourceOptions;
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) {
        final var config = ctx.config();
        final var name = config.get("name").orElse("tf-example");
        final var zone = config.get("zone").orElse(        
            "cn-beijing-i",
            "cn-beijing-k",
            "cn-beijing-l");
        var vpc = new Network("vpc", NetworkArgs.builder()
            .vpcName(name)
            .cidrBlock("10.2.0.0/16")
            .enableIpv6(true)
            .build());

        for (var i = 0; i < 2; i++) {
            new Switch("vsw-" + i, SwitchArgs.builder()
                .enableIpv6(true)
                .ipv6CidrBlockMask(String.format("1%s", range.value()))
                .vswitchName(String.format("vsw-%s-for-nlb", range.value()))
                .vpcId(vpc.id())
                .cidrBlock(String.format("10.2.1%s.0/24", range.value()))
                .zoneId(zone[range.value()])
                .build());

        
}
        var default_ = new Ipv6Gateway("default", Ipv6GatewayArgs.builder()
            .ipv6GatewayName(name)
            .vpcId(vpc.id())
            .build());

        var nlb = new LoadBalancer("nlb", LoadBalancerArgs.builder()
            .loadBalancerName(name)
            .loadBalancerType("Network")
            .addressType("Intranet")
            .addressIpVersion("DualStack")
            .ipv6AddressType("Internet")
            .vpcId(vpc.id())
            .crossZoneEnabled(false)
            .tags(Map.ofEntries(
                Map.entry("Created", "TF"),
                Map.entry("For", "example")
            ))
            .zoneMappings(            
                LoadBalancerZoneMappingArgs.builder()
                    .vswitchId(vsw[0].id())
                    .zoneId(zone[0])
                    .build(),
                LoadBalancerZoneMappingArgs.builder()
                    .vswitchId(vsw[1].id())
                    .zoneId(zone[1])
                    .build())
            .build(), CustomResourceOptions.builder()
                .dependsOn(default_)
                .build());

    }
}
Copy
Coming soon!

Create LoadBalancer Resource

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

Constructor syntax

new LoadBalancer(name: string, args: LoadBalancerArgs, opts?: CustomResourceOptions);
@overload
def LoadBalancer(resource_name: str,
                 args: LoadBalancerArgs,
                 opts: Optional[ResourceOptions] = None)

@overload
def LoadBalancer(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 vpc_id: Optional[str] = None,
                 address_type: Optional[str] = None,
                 zone_mappings: Optional[Sequence[LoadBalancerZoneMappingArgs]] = None,
                 load_balancer_type: Optional[str] = None,
                 modification_protection_reason: Optional[str] = None,
                 deletion_protection_config: Optional[LoadBalancerDeletionProtectionConfigArgs] = None,
                 deletion_protection_enabled: Optional[bool] = None,
                 deletion_protection_reason: Optional[str] = None,
                 ipv6_address_type: Optional[str] = None,
                 load_balancer_name: Optional[str] = None,
                 address_ip_version: Optional[str] = None,
                 modification_protection_config: Optional[LoadBalancerModificationProtectionConfigArgs] = None,
                 cross_zone_enabled: Optional[bool] = None,
                 modification_protection_status: Optional[str] = None,
                 payment_type: Optional[str] = None,
                 resource_group_id: Optional[str] = None,
                 security_group_ids: Optional[Sequence[str]] = None,
                 tags: Optional[Mapping[str, str]] = None,
                 cps: Optional[int] = None,
                 bandwidth_package_id: Optional[str] = None)
func NewLoadBalancer(ctx *Context, name string, args LoadBalancerArgs, opts ...ResourceOption) (*LoadBalancer, error)
public LoadBalancer(string name, LoadBalancerArgs args, CustomResourceOptions? opts = null)
public LoadBalancer(String name, LoadBalancerArgs args)
public LoadBalancer(String name, LoadBalancerArgs args, CustomResourceOptions options)
type: alicloud:nlb:LoadBalancer
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. LoadBalancerArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. LoadBalancerArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. LoadBalancerArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. LoadBalancerArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. LoadBalancerArgs
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 exampleloadBalancerResourceResourceFromNlbloadBalancer = new AliCloud.Nlb.LoadBalancer("exampleloadBalancerResourceResourceFromNlbloadBalancer", new()
{
    VpcId = "string",
    AddressType = "string",
    ZoneMappings = new[]
    {
        new AliCloud.Nlb.Inputs.LoadBalancerZoneMappingArgs
        {
            VswitchId = "string",
            ZoneId = "string",
            AllocationId = "string",
            EniId = "string",
            Ipv4LocalAddresses = new[]
            {
                "string",
            },
            Ipv6Address = "string",
            Ipv6LocalAddresses = new[]
            {
                "string",
            },
            PrivateIpv4Address = "string",
            PublicIpv4Address = "string",
            Status = "string",
        },
    },
    LoadBalancerType = "string",
    ModificationProtectionReason = "string",
    DeletionProtectionConfig = new AliCloud.Nlb.Inputs.LoadBalancerDeletionProtectionConfigArgs
    {
        Enabled = false,
        EnabledTime = "string",
        Reason = "string",
    },
    DeletionProtectionEnabled = false,
    DeletionProtectionReason = "string",
    Ipv6AddressType = "string",
    LoadBalancerName = "string",
    AddressIpVersion = "string",
    ModificationProtectionConfig = new AliCloud.Nlb.Inputs.LoadBalancerModificationProtectionConfigArgs
    {
        EnabledTime = "string",
        Reason = "string",
        Status = "string",
    },
    CrossZoneEnabled = false,
    ModificationProtectionStatus = "string",
    PaymentType = "string",
    ResourceGroupId = "string",
    SecurityGroupIds = new[]
    {
        "string",
    },
    Tags = 
    {
        { "string", "string" },
    },
    Cps = 0,
    BandwidthPackageId = "string",
});
Copy
example, err := nlb.NewLoadBalancer(ctx, "exampleloadBalancerResourceResourceFromNlbloadBalancer", &nlb.LoadBalancerArgs{
	VpcId:       pulumi.String("string"),
	AddressType: pulumi.String("string"),
	ZoneMappings: nlb.LoadBalancerZoneMappingArray{
		&nlb.LoadBalancerZoneMappingArgs{
			VswitchId:    pulumi.String("string"),
			ZoneId:       pulumi.String("string"),
			AllocationId: pulumi.String("string"),
			EniId:        pulumi.String("string"),
			Ipv4LocalAddresses: pulumi.StringArray{
				pulumi.String("string"),
			},
			Ipv6Address: pulumi.String("string"),
			Ipv6LocalAddresses: pulumi.StringArray{
				pulumi.String("string"),
			},
			PrivateIpv4Address: pulumi.String("string"),
			PublicIpv4Address:  pulumi.String("string"),
			Status:             pulumi.String("string"),
		},
	},
	LoadBalancerType:             pulumi.String("string"),
	ModificationProtectionReason: pulumi.String("string"),
	DeletionProtectionConfig: &nlb.LoadBalancerDeletionProtectionConfigArgs{
		Enabled:     pulumi.Bool(false),
		EnabledTime: pulumi.String("string"),
		Reason:      pulumi.String("string"),
	},
	DeletionProtectionEnabled: pulumi.Bool(false),
	DeletionProtectionReason:  pulumi.String("string"),
	Ipv6AddressType:           pulumi.String("string"),
	LoadBalancerName:          pulumi.String("string"),
	AddressIpVersion:          pulumi.String("string"),
	ModificationProtectionConfig: &nlb.LoadBalancerModificationProtectionConfigArgs{
		EnabledTime: pulumi.String("string"),
		Reason:      pulumi.String("string"),
		Status:      pulumi.String("string"),
	},
	CrossZoneEnabled:             pulumi.Bool(false),
	ModificationProtectionStatus: pulumi.String("string"),
	PaymentType:                  pulumi.String("string"),
	ResourceGroupId:              pulumi.String("string"),
	SecurityGroupIds: pulumi.StringArray{
		pulumi.String("string"),
	},
	Tags: pulumi.StringMap{
		"string": pulumi.String("string"),
	},
	Cps:                pulumi.Int(0),
	BandwidthPackageId: pulumi.String("string"),
})
Copy
var exampleloadBalancerResourceResourceFromNlbloadBalancer = new LoadBalancer("exampleloadBalancerResourceResourceFromNlbloadBalancer", LoadBalancerArgs.builder()
    .vpcId("string")
    .addressType("string")
    .zoneMappings(LoadBalancerZoneMappingArgs.builder()
        .vswitchId("string")
        .zoneId("string")
        .allocationId("string")
        .eniId("string")
        .ipv4LocalAddresses("string")
        .ipv6Address("string")
        .ipv6LocalAddresses("string")
        .privateIpv4Address("string")
        .publicIpv4Address("string")
        .status("string")
        .build())
    .loadBalancerType("string")
    .modificationProtectionReason("string")
    .deletionProtectionConfig(LoadBalancerDeletionProtectionConfigArgs.builder()
        .enabled(false)
        .enabledTime("string")
        .reason("string")
        .build())
    .deletionProtectionEnabled(false)
    .deletionProtectionReason("string")
    .ipv6AddressType("string")
    .loadBalancerName("string")
    .addressIpVersion("string")
    .modificationProtectionConfig(LoadBalancerModificationProtectionConfigArgs.builder()
        .enabledTime("string")
        .reason("string")
        .status("string")
        .build())
    .crossZoneEnabled(false)
    .modificationProtectionStatus("string")
    .paymentType("string")
    .resourceGroupId("string")
    .securityGroupIds("string")
    .tags(Map.of("string", "string"))
    .cps(0)
    .bandwidthPackageId("string")
    .build());
Copy
exampleload_balancer_resource_resource_from_nlbload_balancer = alicloud.nlb.LoadBalancer("exampleloadBalancerResourceResourceFromNlbloadBalancer",
    vpc_id="string",
    address_type="string",
    zone_mappings=[{
        "vswitch_id": "string",
        "zone_id": "string",
        "allocation_id": "string",
        "eni_id": "string",
        "ipv4_local_addresses": ["string"],
        "ipv6_address": "string",
        "ipv6_local_addresses": ["string"],
        "private_ipv4_address": "string",
        "public_ipv4_address": "string",
        "status": "string",
    }],
    load_balancer_type="string",
    modification_protection_reason="string",
    deletion_protection_config={
        "enabled": False,
        "enabled_time": "string",
        "reason": "string",
    },
    deletion_protection_enabled=False,
    deletion_protection_reason="string",
    ipv6_address_type="string",
    load_balancer_name="string",
    address_ip_version="string",
    modification_protection_config={
        "enabled_time": "string",
        "reason": "string",
        "status": "string",
    },
    cross_zone_enabled=False,
    modification_protection_status="string",
    payment_type="string",
    resource_group_id="string",
    security_group_ids=["string"],
    tags={
        "string": "string",
    },
    cps=0,
    bandwidth_package_id="string")
Copy
const exampleloadBalancerResourceResourceFromNlbloadBalancer = new alicloud.nlb.LoadBalancer("exampleloadBalancerResourceResourceFromNlbloadBalancer", {
    vpcId: "string",
    addressType: "string",
    zoneMappings: [{
        vswitchId: "string",
        zoneId: "string",
        allocationId: "string",
        eniId: "string",
        ipv4LocalAddresses: ["string"],
        ipv6Address: "string",
        ipv6LocalAddresses: ["string"],
        privateIpv4Address: "string",
        publicIpv4Address: "string",
        status: "string",
    }],
    loadBalancerType: "string",
    modificationProtectionReason: "string",
    deletionProtectionConfig: {
        enabled: false,
        enabledTime: "string",
        reason: "string",
    },
    deletionProtectionEnabled: false,
    deletionProtectionReason: "string",
    ipv6AddressType: "string",
    loadBalancerName: "string",
    addressIpVersion: "string",
    modificationProtectionConfig: {
        enabledTime: "string",
        reason: "string",
        status: "string",
    },
    crossZoneEnabled: false,
    modificationProtectionStatus: "string",
    paymentType: "string",
    resourceGroupId: "string",
    securityGroupIds: ["string"],
    tags: {
        string: "string",
    },
    cps: 0,
    bandwidthPackageId: "string",
});
Copy
type: alicloud:nlb:LoadBalancer
properties:
    addressIpVersion: string
    addressType: string
    bandwidthPackageId: string
    cps: 0
    crossZoneEnabled: false
    deletionProtectionConfig:
        enabled: false
        enabledTime: string
        reason: string
    deletionProtectionEnabled: false
    deletionProtectionReason: string
    ipv6AddressType: string
    loadBalancerName: string
    loadBalancerType: string
    modificationProtectionConfig:
        enabledTime: string
        reason: string
        status: string
    modificationProtectionReason: string
    modificationProtectionStatus: string
    paymentType: string
    resourceGroupId: string
    securityGroupIds:
        - string
    tags:
        string: string
    vpcId: string
    zoneMappings:
        - allocationId: string
          eniId: string
          ipv4LocalAddresses:
            - string
          ipv6Address: string
          ipv6LocalAddresses:
            - string
          privateIpv4Address: string
          publicIpv4Address: string
          status: string
          vswitchId: string
          zoneId: string
Copy

LoadBalancer 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 LoadBalancer resource accepts the following input properties:

AddressType This property is required. string

The type of IPv4 address used by the NLB instance. Valid values:

  • Internet: The NLB instance uses a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: The NLB instance uses a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the virtual private cloud (VPC) where the NLB instance is deployed.

NOTE: To enable a public IPv6 address for an NLB instance, call the EnableLoadBalancerIpv6Internet operation.

VpcId
This property is required.
Changes to this property will trigger replacement.
string
The ID of the VPC where the NLB instance is deployed.
ZoneMappings This property is required. List<Pulumi.AliCloud.Nlb.Inputs.LoadBalancerZoneMapping>
Available Area Configuration List. You must add at least two zones. You can add a maximum of 10 zones. See zone_mappings below.
AddressIpVersion Changes to this property will trigger replacement. string
The protocol version. Valid values:

  • ipv4: IPv4. This is the default value.
  • DualStack: dual stack.
BandwidthPackageId Changes to this property will trigger replacement. string
The ID of the EIP bandwidth plan that is associated with the Internet-facing NLB instance.
Cps int
The speed limit of new connections per second processed by NLB instances in each VIP. Value range: 0 to 1000000.

  • 0* means no speed limit.
CrossZoneEnabled bool
Specifies whether to enable cross-zone load balancing for the NLB instance. Valid values:
DeletionProtectionConfig Pulumi.AliCloud.Nlb.Inputs.LoadBalancerDeletionProtectionConfig
Specifies whether to enable deletion protection. Default value: false. See deletion_protection_config below.
DeletionProtectionEnabled bool
Specifies whether to enable deletion protection. Default value: false. Valid values:
DeletionProtectionReason string
The reason why the deletion protection feature is enabled or disabled. The deletion_protection_reason takes effect only when deletion_protection_enabled is set to true.
Ipv6AddressType string
The type of IPv6 address used by the NLB instance. Valid values:

  • Internet: a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the VPC where the NLB instance is deployed.
LoadBalancerName string
The name of the NLB instance. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.
LoadBalancerType Changes to this property will trigger replacement. string
The type of the Server Load Balancer (SLB) instance. Set the value to network, which specifies NLB.
ModificationProtectionConfig Pulumi.AliCloud.Nlb.Inputs.LoadBalancerModificationProtectionConfig
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. See modification_protection_config below.
ModificationProtectionReason string
The reason why the configuration read-only mode is enabled. The modification_protection_reason takes effect only when modification_protection_status is set to ConsoleProtection.
ModificationProtectionStatus string
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. Valid values:

  • NonProtection: Does not enable the configuration read-only mode. You cannot set the modification_protection_reason. If the modification_protection_reason is set, the value is cleared.
  • ConsoleProtection: Enables the configuration read-only mode. You can set the modification_protection_reason.
PaymentType Changes to this property will trigger replacement. string
The payment type of the resource
ResourceGroupId string
The ID of the new resource group. You can log on to the Resource Management console to view resource group IDs.
SecurityGroupIds List<string>
The security group to which the network-based SLB instance belongs.
Tags Dictionary<string, string>
List of labels.
AddressType This property is required. string

The type of IPv4 address used by the NLB instance. Valid values:

  • Internet: The NLB instance uses a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: The NLB instance uses a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the virtual private cloud (VPC) where the NLB instance is deployed.

NOTE: To enable a public IPv6 address for an NLB instance, call the EnableLoadBalancerIpv6Internet operation.

VpcId
This property is required.
Changes to this property will trigger replacement.
string
The ID of the VPC where the NLB instance is deployed.
ZoneMappings This property is required. []LoadBalancerZoneMappingArgs
Available Area Configuration List. You must add at least two zones. You can add a maximum of 10 zones. See zone_mappings below.
AddressIpVersion Changes to this property will trigger replacement. string
The protocol version. Valid values:

  • ipv4: IPv4. This is the default value.
  • DualStack: dual stack.
BandwidthPackageId Changes to this property will trigger replacement. string
The ID of the EIP bandwidth plan that is associated with the Internet-facing NLB instance.
Cps int
The speed limit of new connections per second processed by NLB instances in each VIP. Value range: 0 to 1000000.

  • 0* means no speed limit.
CrossZoneEnabled bool
Specifies whether to enable cross-zone load balancing for the NLB instance. Valid values:
DeletionProtectionConfig LoadBalancerDeletionProtectionConfigArgs
Specifies whether to enable deletion protection. Default value: false. See deletion_protection_config below.
DeletionProtectionEnabled bool
Specifies whether to enable deletion protection. Default value: false. Valid values:
DeletionProtectionReason string
The reason why the deletion protection feature is enabled or disabled. The deletion_protection_reason takes effect only when deletion_protection_enabled is set to true.
Ipv6AddressType string
The type of IPv6 address used by the NLB instance. Valid values:

  • Internet: a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the VPC where the NLB instance is deployed.
LoadBalancerName string
The name of the NLB instance. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.
LoadBalancerType Changes to this property will trigger replacement. string
The type of the Server Load Balancer (SLB) instance. Set the value to network, which specifies NLB.
ModificationProtectionConfig LoadBalancerModificationProtectionConfigArgs
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. See modification_protection_config below.
ModificationProtectionReason string
The reason why the configuration read-only mode is enabled. The modification_protection_reason takes effect only when modification_protection_status is set to ConsoleProtection.
ModificationProtectionStatus string
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. Valid values:

  • NonProtection: Does not enable the configuration read-only mode. You cannot set the modification_protection_reason. If the modification_protection_reason is set, the value is cleared.
  • ConsoleProtection: Enables the configuration read-only mode. You can set the modification_protection_reason.
PaymentType Changes to this property will trigger replacement. string
The payment type of the resource
ResourceGroupId string
The ID of the new resource group. You can log on to the Resource Management console to view resource group IDs.
SecurityGroupIds []string
The security group to which the network-based SLB instance belongs.
Tags map[string]string
List of labels.
addressType This property is required. String

The type of IPv4 address used by the NLB instance. Valid values:

  • Internet: The NLB instance uses a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: The NLB instance uses a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the virtual private cloud (VPC) where the NLB instance is deployed.

NOTE: To enable a public IPv6 address for an NLB instance, call the EnableLoadBalancerIpv6Internet operation.

vpcId
This property is required.
Changes to this property will trigger replacement.
String
The ID of the VPC where the NLB instance is deployed.
zoneMappings This property is required. List<LoadBalancerZoneMapping>
Available Area Configuration List. You must add at least two zones. You can add a maximum of 10 zones. See zone_mappings below.
addressIpVersion Changes to this property will trigger replacement. String
The protocol version. Valid values:

  • ipv4: IPv4. This is the default value.
  • DualStack: dual stack.
bandwidthPackageId Changes to this property will trigger replacement. String
The ID of the EIP bandwidth plan that is associated with the Internet-facing NLB instance.
cps Integer
The speed limit of new connections per second processed by NLB instances in each VIP. Value range: 0 to 1000000.

  • 0* means no speed limit.
crossZoneEnabled Boolean
Specifies whether to enable cross-zone load balancing for the NLB instance. Valid values:
deletionProtectionConfig LoadBalancerDeletionProtectionConfig
Specifies whether to enable deletion protection. Default value: false. See deletion_protection_config below.
deletionProtectionEnabled Boolean
Specifies whether to enable deletion protection. Default value: false. Valid values:
deletionProtectionReason String
The reason why the deletion protection feature is enabled or disabled. The deletion_protection_reason takes effect only when deletion_protection_enabled is set to true.
ipv6AddressType String
The type of IPv6 address used by the NLB instance. Valid values:

  • Internet: a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the VPC where the NLB instance is deployed.
loadBalancerName String
The name of the NLB instance. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.
loadBalancerType Changes to this property will trigger replacement. String
The type of the Server Load Balancer (SLB) instance. Set the value to network, which specifies NLB.
modificationProtectionConfig LoadBalancerModificationProtectionConfig
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. See modification_protection_config below.
modificationProtectionReason String
The reason why the configuration read-only mode is enabled. The modification_protection_reason takes effect only when modification_protection_status is set to ConsoleProtection.
modificationProtectionStatus String
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. Valid values:

  • NonProtection: Does not enable the configuration read-only mode. You cannot set the modification_protection_reason. If the modification_protection_reason is set, the value is cleared.
  • ConsoleProtection: Enables the configuration read-only mode. You can set the modification_protection_reason.
paymentType Changes to this property will trigger replacement. String
The payment type of the resource
resourceGroupId String
The ID of the new resource group. You can log on to the Resource Management console to view resource group IDs.
securityGroupIds List<String>
The security group to which the network-based SLB instance belongs.
tags Map<String,String>
List of labels.
addressType This property is required. string

The type of IPv4 address used by the NLB instance. Valid values:

  • Internet: The NLB instance uses a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: The NLB instance uses a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the virtual private cloud (VPC) where the NLB instance is deployed.

NOTE: To enable a public IPv6 address for an NLB instance, call the EnableLoadBalancerIpv6Internet operation.

vpcId
This property is required.
Changes to this property will trigger replacement.
string
The ID of the VPC where the NLB instance is deployed.
zoneMappings This property is required. LoadBalancerZoneMapping[]
Available Area Configuration List. You must add at least two zones. You can add a maximum of 10 zones. See zone_mappings below.
addressIpVersion Changes to this property will trigger replacement. string
The protocol version. Valid values:

  • ipv4: IPv4. This is the default value.
  • DualStack: dual stack.
bandwidthPackageId Changes to this property will trigger replacement. string
The ID of the EIP bandwidth plan that is associated with the Internet-facing NLB instance.
cps number
The speed limit of new connections per second processed by NLB instances in each VIP. Value range: 0 to 1000000.

  • 0* means no speed limit.
crossZoneEnabled boolean
Specifies whether to enable cross-zone load balancing for the NLB instance. Valid values:
deletionProtectionConfig LoadBalancerDeletionProtectionConfig
Specifies whether to enable deletion protection. Default value: false. See deletion_protection_config below.
deletionProtectionEnabled boolean
Specifies whether to enable deletion protection. Default value: false. Valid values:
deletionProtectionReason string
The reason why the deletion protection feature is enabled or disabled. The deletion_protection_reason takes effect only when deletion_protection_enabled is set to true.
ipv6AddressType string
The type of IPv6 address used by the NLB instance. Valid values:

  • Internet: a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the VPC where the NLB instance is deployed.
loadBalancerName string
The name of the NLB instance. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.
loadBalancerType Changes to this property will trigger replacement. string
The type of the Server Load Balancer (SLB) instance. Set the value to network, which specifies NLB.
modificationProtectionConfig LoadBalancerModificationProtectionConfig
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. See modification_protection_config below.
modificationProtectionReason string
The reason why the configuration read-only mode is enabled. The modification_protection_reason takes effect only when modification_protection_status is set to ConsoleProtection.
modificationProtectionStatus string
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. Valid values:

  • NonProtection: Does not enable the configuration read-only mode. You cannot set the modification_protection_reason. If the modification_protection_reason is set, the value is cleared.
  • ConsoleProtection: Enables the configuration read-only mode. You can set the modification_protection_reason.
paymentType Changes to this property will trigger replacement. string
The payment type of the resource
resourceGroupId string
The ID of the new resource group. You can log on to the Resource Management console to view resource group IDs.
securityGroupIds string[]
The security group to which the network-based SLB instance belongs.
tags {[key: string]: string}
List of labels.
address_type This property is required. str

The type of IPv4 address used by the NLB instance. Valid values:

  • Internet: The NLB instance uses a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: The NLB instance uses a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the virtual private cloud (VPC) where the NLB instance is deployed.

NOTE: To enable a public IPv6 address for an NLB instance, call the EnableLoadBalancerIpv6Internet operation.

vpc_id
This property is required.
Changes to this property will trigger replacement.
str
The ID of the VPC where the NLB instance is deployed.
zone_mappings This property is required. Sequence[LoadBalancerZoneMappingArgs]
Available Area Configuration List. You must add at least two zones. You can add a maximum of 10 zones. See zone_mappings below.
address_ip_version Changes to this property will trigger replacement. str
The protocol version. Valid values:

  • ipv4: IPv4. This is the default value.
  • DualStack: dual stack.
bandwidth_package_id Changes to this property will trigger replacement. str
The ID of the EIP bandwidth plan that is associated with the Internet-facing NLB instance.
cps int
The speed limit of new connections per second processed by NLB instances in each VIP. Value range: 0 to 1000000.

  • 0* means no speed limit.
cross_zone_enabled bool
Specifies whether to enable cross-zone load balancing for the NLB instance. Valid values:
deletion_protection_config LoadBalancerDeletionProtectionConfigArgs
Specifies whether to enable deletion protection. Default value: false. See deletion_protection_config below.
deletion_protection_enabled bool
Specifies whether to enable deletion protection. Default value: false. Valid values:
deletion_protection_reason str
The reason why the deletion protection feature is enabled or disabled. The deletion_protection_reason takes effect only when deletion_protection_enabled is set to true.
ipv6_address_type str
The type of IPv6 address used by the NLB instance. Valid values:

  • Internet: a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the VPC where the NLB instance is deployed.
load_balancer_name str
The name of the NLB instance. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.
load_balancer_type Changes to this property will trigger replacement. str
The type of the Server Load Balancer (SLB) instance. Set the value to network, which specifies NLB.
modification_protection_config LoadBalancerModificationProtectionConfigArgs
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. See modification_protection_config below.
modification_protection_reason str
The reason why the configuration read-only mode is enabled. The modification_protection_reason takes effect only when modification_protection_status is set to ConsoleProtection.
modification_protection_status str
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. Valid values:

  • NonProtection: Does not enable the configuration read-only mode. You cannot set the modification_protection_reason. If the modification_protection_reason is set, the value is cleared.
  • ConsoleProtection: Enables the configuration read-only mode. You can set the modification_protection_reason.
payment_type Changes to this property will trigger replacement. str
The payment type of the resource
resource_group_id str
The ID of the new resource group. You can log on to the Resource Management console to view resource group IDs.
security_group_ids Sequence[str]
The security group to which the network-based SLB instance belongs.
tags Mapping[str, str]
List of labels.
addressType This property is required. String

The type of IPv4 address used by the NLB instance. Valid values:

  • Internet: The NLB instance uses a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: The NLB instance uses a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the virtual private cloud (VPC) where the NLB instance is deployed.

NOTE: To enable a public IPv6 address for an NLB instance, call the EnableLoadBalancerIpv6Internet operation.

vpcId
This property is required.
Changes to this property will trigger replacement.
String
The ID of the VPC where the NLB instance is deployed.
zoneMappings This property is required. List<Property Map>
Available Area Configuration List. You must add at least two zones. You can add a maximum of 10 zones. See zone_mappings below.
addressIpVersion Changes to this property will trigger replacement. String
The protocol version. Valid values:

  • ipv4: IPv4. This is the default value.
  • DualStack: dual stack.
bandwidthPackageId Changes to this property will trigger replacement. String
The ID of the EIP bandwidth plan that is associated with the Internet-facing NLB instance.
cps Number
The speed limit of new connections per second processed by NLB instances in each VIP. Value range: 0 to 1000000.

  • 0* means no speed limit.
crossZoneEnabled Boolean
Specifies whether to enable cross-zone load balancing for the NLB instance. Valid values:
deletionProtectionConfig Property Map
Specifies whether to enable deletion protection. Default value: false. See deletion_protection_config below.
deletionProtectionEnabled Boolean
Specifies whether to enable deletion protection. Default value: false. Valid values:
deletionProtectionReason String
The reason why the deletion protection feature is enabled or disabled. The deletion_protection_reason takes effect only when deletion_protection_enabled is set to true.
ipv6AddressType String
The type of IPv6 address used by the NLB instance. Valid values:

  • Internet: a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the VPC where the NLB instance is deployed.
loadBalancerName String
The name of the NLB instance. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.
loadBalancerType Changes to this property will trigger replacement. String
The type of the Server Load Balancer (SLB) instance. Set the value to network, which specifies NLB.
modificationProtectionConfig Property Map
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. See modification_protection_config below.
modificationProtectionReason String
The reason why the configuration read-only mode is enabled. The modification_protection_reason takes effect only when modification_protection_status is set to ConsoleProtection.
modificationProtectionStatus String
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. Valid values:

  • NonProtection: Does not enable the configuration read-only mode. You cannot set the modification_protection_reason. If the modification_protection_reason is set, the value is cleared.
  • ConsoleProtection: Enables the configuration read-only mode. You can set the modification_protection_reason.
paymentType Changes to this property will trigger replacement. String
The payment type of the resource
resourceGroupId String
The ID of the new resource group. You can log on to the Resource Management console to view resource group IDs.
securityGroupIds List<String>
The security group to which the network-based SLB instance belongs.
tags Map<String>
List of labels.

Outputs

All input properties are implicitly available as output properties. Additionally, the LoadBalancer resource produces the following output properties:

CreateTime string
Resource creation time, using Greenwich Mean Time, formating' yyyy-MM-ddTHH:mm:ssZ '.
DnsName string
The domain name of the NLB instance.
Id string
The provider-assigned unique ID for this managed resource.
LoadBalancerBusinessStatus string
The business status of the NLB instance.
RegionId string
The ID of the region where the NLB instance is deployed.
Status string
Zone Status
CreateTime string
Resource creation time, using Greenwich Mean Time, formating' yyyy-MM-ddTHH:mm:ssZ '.
DnsName string
The domain name of the NLB instance.
Id string
The provider-assigned unique ID for this managed resource.
LoadBalancerBusinessStatus string
The business status of the NLB instance.
RegionId string
The ID of the region where the NLB instance is deployed.
Status string
Zone Status
createTime String
Resource creation time, using Greenwich Mean Time, formating' yyyy-MM-ddTHH:mm:ssZ '.
dnsName String
The domain name of the NLB instance.
id String
The provider-assigned unique ID for this managed resource.
loadBalancerBusinessStatus String
The business status of the NLB instance.
regionId String
The ID of the region where the NLB instance is deployed.
status String
Zone Status
createTime string
Resource creation time, using Greenwich Mean Time, formating' yyyy-MM-ddTHH:mm:ssZ '.
dnsName string
The domain name of the NLB instance.
id string
The provider-assigned unique ID for this managed resource.
loadBalancerBusinessStatus string
The business status of the NLB instance.
regionId string
The ID of the region where the NLB instance is deployed.
status string
Zone Status
create_time str
Resource creation time, using Greenwich Mean Time, formating' yyyy-MM-ddTHH:mm:ssZ '.
dns_name str
The domain name of the NLB instance.
id str
The provider-assigned unique ID for this managed resource.
load_balancer_business_status str
The business status of the NLB instance.
region_id str
The ID of the region where the NLB instance is deployed.
status str
Zone Status
createTime String
Resource creation time, using Greenwich Mean Time, formating' yyyy-MM-ddTHH:mm:ssZ '.
dnsName String
The domain name of the NLB instance.
id String
The provider-assigned unique ID for this managed resource.
loadBalancerBusinessStatus String
The business status of the NLB instance.
regionId String
The ID of the region where the NLB instance is deployed.
status String
Zone Status

Look up Existing LoadBalancer Resource

Get an existing LoadBalancer 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?: LoadBalancerState, opts?: CustomResourceOptions): LoadBalancer
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        address_ip_version: Optional[str] = None,
        address_type: Optional[str] = None,
        bandwidth_package_id: Optional[str] = None,
        cps: Optional[int] = None,
        create_time: Optional[str] = None,
        cross_zone_enabled: Optional[bool] = None,
        deletion_protection_config: Optional[LoadBalancerDeletionProtectionConfigArgs] = None,
        deletion_protection_enabled: Optional[bool] = None,
        deletion_protection_reason: Optional[str] = None,
        dns_name: Optional[str] = None,
        ipv6_address_type: Optional[str] = None,
        load_balancer_business_status: Optional[str] = None,
        load_balancer_name: Optional[str] = None,
        load_balancer_type: Optional[str] = None,
        modification_protection_config: Optional[LoadBalancerModificationProtectionConfigArgs] = None,
        modification_protection_reason: Optional[str] = None,
        modification_protection_status: Optional[str] = None,
        payment_type: Optional[str] = None,
        region_id: Optional[str] = None,
        resource_group_id: Optional[str] = None,
        security_group_ids: Optional[Sequence[str]] = None,
        status: Optional[str] = None,
        tags: Optional[Mapping[str, str]] = None,
        vpc_id: Optional[str] = None,
        zone_mappings: Optional[Sequence[LoadBalancerZoneMappingArgs]] = None) -> LoadBalancer
func GetLoadBalancer(ctx *Context, name string, id IDInput, state *LoadBalancerState, opts ...ResourceOption) (*LoadBalancer, error)
public static LoadBalancer Get(string name, Input<string> id, LoadBalancerState? state, CustomResourceOptions? opts = null)
public static LoadBalancer get(String name, Output<String> id, LoadBalancerState state, CustomResourceOptions options)
resources:  _:    type: alicloud:nlb:LoadBalancer    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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:
AddressIpVersion Changes to this property will trigger replacement. string
The protocol version. Valid values:

  • ipv4: IPv4. This is the default value.
  • DualStack: dual stack.
AddressType string

The type of IPv4 address used by the NLB instance. Valid values:

  • Internet: The NLB instance uses a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: The NLB instance uses a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the virtual private cloud (VPC) where the NLB instance is deployed.

NOTE: To enable a public IPv6 address for an NLB instance, call the EnableLoadBalancerIpv6Internet operation.

BandwidthPackageId Changes to this property will trigger replacement. string
The ID of the EIP bandwidth plan that is associated with the Internet-facing NLB instance.
Cps int
The speed limit of new connections per second processed by NLB instances in each VIP. Value range: 0 to 1000000.

  • 0* means no speed limit.
CreateTime string
Resource creation time, using Greenwich Mean Time, formating' yyyy-MM-ddTHH:mm:ssZ '.
CrossZoneEnabled bool
Specifies whether to enable cross-zone load balancing for the NLB instance. Valid values:
DeletionProtectionConfig Pulumi.AliCloud.Nlb.Inputs.LoadBalancerDeletionProtectionConfig
Specifies whether to enable deletion protection. Default value: false. See deletion_protection_config below.
DeletionProtectionEnabled bool
Specifies whether to enable deletion protection. Default value: false. Valid values:
DeletionProtectionReason string
The reason why the deletion protection feature is enabled or disabled. The deletion_protection_reason takes effect only when deletion_protection_enabled is set to true.
DnsName string
The domain name of the NLB instance.
Ipv6AddressType string
The type of IPv6 address used by the NLB instance. Valid values:

  • Internet: a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the VPC where the NLB instance is deployed.
LoadBalancerBusinessStatus string
The business status of the NLB instance.
LoadBalancerName string
The name of the NLB instance. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.
LoadBalancerType Changes to this property will trigger replacement. string
The type of the Server Load Balancer (SLB) instance. Set the value to network, which specifies NLB.
ModificationProtectionConfig Pulumi.AliCloud.Nlb.Inputs.LoadBalancerModificationProtectionConfig
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. See modification_protection_config below.
ModificationProtectionReason string
The reason why the configuration read-only mode is enabled. The modification_protection_reason takes effect only when modification_protection_status is set to ConsoleProtection.
ModificationProtectionStatus string
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. Valid values:

  • NonProtection: Does not enable the configuration read-only mode. You cannot set the modification_protection_reason. If the modification_protection_reason is set, the value is cleared.
  • ConsoleProtection: Enables the configuration read-only mode. You can set the modification_protection_reason.
PaymentType Changes to this property will trigger replacement. string
The payment type of the resource
RegionId string
The ID of the region where the NLB instance is deployed.
ResourceGroupId string
The ID of the new resource group. You can log on to the Resource Management console to view resource group IDs.
SecurityGroupIds List<string>
The security group to which the network-based SLB instance belongs.
Status string
Zone Status
Tags Dictionary<string, string>
List of labels.
VpcId Changes to this property will trigger replacement. string
The ID of the VPC where the NLB instance is deployed.
ZoneMappings List<Pulumi.AliCloud.Nlb.Inputs.LoadBalancerZoneMapping>
Available Area Configuration List. You must add at least two zones. You can add a maximum of 10 zones. See zone_mappings below.
AddressIpVersion Changes to this property will trigger replacement. string
The protocol version. Valid values:

  • ipv4: IPv4. This is the default value.
  • DualStack: dual stack.
AddressType string

The type of IPv4 address used by the NLB instance. Valid values:

  • Internet: The NLB instance uses a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: The NLB instance uses a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the virtual private cloud (VPC) where the NLB instance is deployed.

NOTE: To enable a public IPv6 address for an NLB instance, call the EnableLoadBalancerIpv6Internet operation.

BandwidthPackageId Changes to this property will trigger replacement. string
The ID of the EIP bandwidth plan that is associated with the Internet-facing NLB instance.
Cps int
The speed limit of new connections per second processed by NLB instances in each VIP. Value range: 0 to 1000000.

  • 0* means no speed limit.
CreateTime string
Resource creation time, using Greenwich Mean Time, formating' yyyy-MM-ddTHH:mm:ssZ '.
CrossZoneEnabled bool
Specifies whether to enable cross-zone load balancing for the NLB instance. Valid values:
DeletionProtectionConfig LoadBalancerDeletionProtectionConfigArgs
Specifies whether to enable deletion protection. Default value: false. See deletion_protection_config below.
DeletionProtectionEnabled bool
Specifies whether to enable deletion protection. Default value: false. Valid values:
DeletionProtectionReason string
The reason why the deletion protection feature is enabled or disabled. The deletion_protection_reason takes effect only when deletion_protection_enabled is set to true.
DnsName string
The domain name of the NLB instance.
Ipv6AddressType string
The type of IPv6 address used by the NLB instance. Valid values:

  • Internet: a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the VPC where the NLB instance is deployed.
LoadBalancerBusinessStatus string
The business status of the NLB instance.
LoadBalancerName string
The name of the NLB instance. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.
LoadBalancerType Changes to this property will trigger replacement. string
The type of the Server Load Balancer (SLB) instance. Set the value to network, which specifies NLB.
ModificationProtectionConfig LoadBalancerModificationProtectionConfigArgs
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. See modification_protection_config below.
ModificationProtectionReason string
The reason why the configuration read-only mode is enabled. The modification_protection_reason takes effect only when modification_protection_status is set to ConsoleProtection.
ModificationProtectionStatus string
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. Valid values:

  • NonProtection: Does not enable the configuration read-only mode. You cannot set the modification_protection_reason. If the modification_protection_reason is set, the value is cleared.
  • ConsoleProtection: Enables the configuration read-only mode. You can set the modification_protection_reason.
PaymentType Changes to this property will trigger replacement. string
The payment type of the resource
RegionId string
The ID of the region where the NLB instance is deployed.
ResourceGroupId string
The ID of the new resource group. You can log on to the Resource Management console to view resource group IDs.
SecurityGroupIds []string
The security group to which the network-based SLB instance belongs.
Status string
Zone Status
Tags map[string]string
List of labels.
VpcId Changes to this property will trigger replacement. string
The ID of the VPC where the NLB instance is deployed.
ZoneMappings []LoadBalancerZoneMappingArgs
Available Area Configuration List. You must add at least two zones. You can add a maximum of 10 zones. See zone_mappings below.
addressIpVersion Changes to this property will trigger replacement. String
The protocol version. Valid values:

  • ipv4: IPv4. This is the default value.
  • DualStack: dual stack.
addressType String

The type of IPv4 address used by the NLB instance. Valid values:

  • Internet: The NLB instance uses a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: The NLB instance uses a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the virtual private cloud (VPC) where the NLB instance is deployed.

NOTE: To enable a public IPv6 address for an NLB instance, call the EnableLoadBalancerIpv6Internet operation.

bandwidthPackageId Changes to this property will trigger replacement. String
The ID of the EIP bandwidth plan that is associated with the Internet-facing NLB instance.
cps Integer
The speed limit of new connections per second processed by NLB instances in each VIP. Value range: 0 to 1000000.

  • 0* means no speed limit.
createTime String
Resource creation time, using Greenwich Mean Time, formating' yyyy-MM-ddTHH:mm:ssZ '.
crossZoneEnabled Boolean
Specifies whether to enable cross-zone load balancing for the NLB instance. Valid values:
deletionProtectionConfig LoadBalancerDeletionProtectionConfig
Specifies whether to enable deletion protection. Default value: false. See deletion_protection_config below.
deletionProtectionEnabled Boolean
Specifies whether to enable deletion protection. Default value: false. Valid values:
deletionProtectionReason String
The reason why the deletion protection feature is enabled or disabled. The deletion_protection_reason takes effect only when deletion_protection_enabled is set to true.
dnsName String
The domain name of the NLB instance.
ipv6AddressType String
The type of IPv6 address used by the NLB instance. Valid values:

  • Internet: a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the VPC where the NLB instance is deployed.
loadBalancerBusinessStatus String
The business status of the NLB instance.
loadBalancerName String
The name of the NLB instance. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.
loadBalancerType Changes to this property will trigger replacement. String
The type of the Server Load Balancer (SLB) instance. Set the value to network, which specifies NLB.
modificationProtectionConfig LoadBalancerModificationProtectionConfig
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. See modification_protection_config below.
modificationProtectionReason String
The reason why the configuration read-only mode is enabled. The modification_protection_reason takes effect only when modification_protection_status is set to ConsoleProtection.
modificationProtectionStatus String
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. Valid values:

  • NonProtection: Does not enable the configuration read-only mode. You cannot set the modification_protection_reason. If the modification_protection_reason is set, the value is cleared.
  • ConsoleProtection: Enables the configuration read-only mode. You can set the modification_protection_reason.
paymentType Changes to this property will trigger replacement. String
The payment type of the resource
regionId String
The ID of the region where the NLB instance is deployed.
resourceGroupId String
The ID of the new resource group. You can log on to the Resource Management console to view resource group IDs.
securityGroupIds List<String>
The security group to which the network-based SLB instance belongs.
status String
Zone Status
tags Map<String,String>
List of labels.
vpcId Changes to this property will trigger replacement. String
The ID of the VPC where the NLB instance is deployed.
zoneMappings List<LoadBalancerZoneMapping>
Available Area Configuration List. You must add at least two zones. You can add a maximum of 10 zones. See zone_mappings below.
addressIpVersion Changes to this property will trigger replacement. string
The protocol version. Valid values:

  • ipv4: IPv4. This is the default value.
  • DualStack: dual stack.
addressType string

The type of IPv4 address used by the NLB instance. Valid values:

  • Internet: The NLB instance uses a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: The NLB instance uses a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the virtual private cloud (VPC) where the NLB instance is deployed.

NOTE: To enable a public IPv6 address for an NLB instance, call the EnableLoadBalancerIpv6Internet operation.

bandwidthPackageId Changes to this property will trigger replacement. string
The ID of the EIP bandwidth plan that is associated with the Internet-facing NLB instance.
cps number
The speed limit of new connections per second processed by NLB instances in each VIP. Value range: 0 to 1000000.

  • 0* means no speed limit.
createTime string
Resource creation time, using Greenwich Mean Time, formating' yyyy-MM-ddTHH:mm:ssZ '.
crossZoneEnabled boolean
Specifies whether to enable cross-zone load balancing for the NLB instance. Valid values:
deletionProtectionConfig LoadBalancerDeletionProtectionConfig
Specifies whether to enable deletion protection. Default value: false. See deletion_protection_config below.
deletionProtectionEnabled boolean
Specifies whether to enable deletion protection. Default value: false. Valid values:
deletionProtectionReason string
The reason why the deletion protection feature is enabled or disabled. The deletion_protection_reason takes effect only when deletion_protection_enabled is set to true.
dnsName string
The domain name of the NLB instance.
ipv6AddressType string
The type of IPv6 address used by the NLB instance. Valid values:

  • Internet: a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the VPC where the NLB instance is deployed.
loadBalancerBusinessStatus string
The business status of the NLB instance.
loadBalancerName string
The name of the NLB instance. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.
loadBalancerType Changes to this property will trigger replacement. string
The type of the Server Load Balancer (SLB) instance. Set the value to network, which specifies NLB.
modificationProtectionConfig LoadBalancerModificationProtectionConfig
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. See modification_protection_config below.
modificationProtectionReason string
The reason why the configuration read-only mode is enabled. The modification_protection_reason takes effect only when modification_protection_status is set to ConsoleProtection.
modificationProtectionStatus string
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. Valid values:

  • NonProtection: Does not enable the configuration read-only mode. You cannot set the modification_protection_reason. If the modification_protection_reason is set, the value is cleared.
  • ConsoleProtection: Enables the configuration read-only mode. You can set the modification_protection_reason.
paymentType Changes to this property will trigger replacement. string
The payment type of the resource
regionId string
The ID of the region where the NLB instance is deployed.
resourceGroupId string
The ID of the new resource group. You can log on to the Resource Management console to view resource group IDs.
securityGroupIds string[]
The security group to which the network-based SLB instance belongs.
status string
Zone Status
tags {[key: string]: string}
List of labels.
vpcId Changes to this property will trigger replacement. string
The ID of the VPC where the NLB instance is deployed.
zoneMappings LoadBalancerZoneMapping[]
Available Area Configuration List. You must add at least two zones. You can add a maximum of 10 zones. See zone_mappings below.
address_ip_version Changes to this property will trigger replacement. str
The protocol version. Valid values:

  • ipv4: IPv4. This is the default value.
  • DualStack: dual stack.
address_type str

The type of IPv4 address used by the NLB instance. Valid values:

  • Internet: The NLB instance uses a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: The NLB instance uses a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the virtual private cloud (VPC) where the NLB instance is deployed.

NOTE: To enable a public IPv6 address for an NLB instance, call the EnableLoadBalancerIpv6Internet operation.

bandwidth_package_id Changes to this property will trigger replacement. str
The ID of the EIP bandwidth plan that is associated with the Internet-facing NLB instance.
cps int
The speed limit of new connections per second processed by NLB instances in each VIP. Value range: 0 to 1000000.

  • 0* means no speed limit.
create_time str
Resource creation time, using Greenwich Mean Time, formating' yyyy-MM-ddTHH:mm:ssZ '.
cross_zone_enabled bool
Specifies whether to enable cross-zone load balancing for the NLB instance. Valid values:
deletion_protection_config LoadBalancerDeletionProtectionConfigArgs
Specifies whether to enable deletion protection. Default value: false. See deletion_protection_config below.
deletion_protection_enabled bool
Specifies whether to enable deletion protection. Default value: false. Valid values:
deletion_protection_reason str
The reason why the deletion protection feature is enabled or disabled. The deletion_protection_reason takes effect only when deletion_protection_enabled is set to true.
dns_name str
The domain name of the NLB instance.
ipv6_address_type str
The type of IPv6 address used by the NLB instance. Valid values:

  • Internet: a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the VPC where the NLB instance is deployed.
load_balancer_business_status str
The business status of the NLB instance.
load_balancer_name str
The name of the NLB instance. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.
load_balancer_type Changes to this property will trigger replacement. str
The type of the Server Load Balancer (SLB) instance. Set the value to network, which specifies NLB.
modification_protection_config LoadBalancerModificationProtectionConfigArgs
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. See modification_protection_config below.
modification_protection_reason str
The reason why the configuration read-only mode is enabled. The modification_protection_reason takes effect only when modification_protection_status is set to ConsoleProtection.
modification_protection_status str
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. Valid values:

  • NonProtection: Does not enable the configuration read-only mode. You cannot set the modification_protection_reason. If the modification_protection_reason is set, the value is cleared.
  • ConsoleProtection: Enables the configuration read-only mode. You can set the modification_protection_reason.
payment_type Changes to this property will trigger replacement. str
The payment type of the resource
region_id str
The ID of the region where the NLB instance is deployed.
resource_group_id str
The ID of the new resource group. You can log on to the Resource Management console to view resource group IDs.
security_group_ids Sequence[str]
The security group to which the network-based SLB instance belongs.
status str
Zone Status
tags Mapping[str, str]
List of labels.
vpc_id Changes to this property will trigger replacement. str
The ID of the VPC where the NLB instance is deployed.
zone_mappings Sequence[LoadBalancerZoneMappingArgs]
Available Area Configuration List. You must add at least two zones. You can add a maximum of 10 zones. See zone_mappings below.
addressIpVersion Changes to this property will trigger replacement. String
The protocol version. Valid values:

  • ipv4: IPv4. This is the default value.
  • DualStack: dual stack.
addressType String

The type of IPv4 address used by the NLB instance. Valid values:

  • Internet: The NLB instance uses a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: The NLB instance uses a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the virtual private cloud (VPC) where the NLB instance is deployed.

NOTE: To enable a public IPv6 address for an NLB instance, call the EnableLoadBalancerIpv6Internet operation.

bandwidthPackageId Changes to this property will trigger replacement. String
The ID of the EIP bandwidth plan that is associated with the Internet-facing NLB instance.
cps Number
The speed limit of new connections per second processed by NLB instances in each VIP. Value range: 0 to 1000000.

  • 0* means no speed limit.
createTime String
Resource creation time, using Greenwich Mean Time, formating' yyyy-MM-ddTHH:mm:ssZ '.
crossZoneEnabled Boolean
Specifies whether to enable cross-zone load balancing for the NLB instance. Valid values:
deletionProtectionConfig Property Map
Specifies whether to enable deletion protection. Default value: false. See deletion_protection_config below.
deletionProtectionEnabled Boolean
Specifies whether to enable deletion protection. Default value: false. Valid values:
deletionProtectionReason String
The reason why the deletion protection feature is enabled or disabled. The deletion_protection_reason takes effect only when deletion_protection_enabled is set to true.
dnsName String
The domain name of the NLB instance.
ipv6AddressType String
The type of IPv6 address used by the NLB instance. Valid values:

  • Internet: a public IP address. The domain name of the NLB instance is resolved to the public IP address. Therefore, the NLB instance can be accessed over the Internet.
  • Intranet: a private IP address. The domain name of the NLB instance is resolved to the private IP address. Therefore, the NLB instance can be accessed over the VPC where the NLB instance is deployed.
loadBalancerBusinessStatus String
The business status of the NLB instance.
loadBalancerName String
The name of the NLB instance. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.
loadBalancerType Changes to this property will trigger replacement. String
The type of the Server Load Balancer (SLB) instance. Set the value to network, which specifies NLB.
modificationProtectionConfig Property Map
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. See modification_protection_config below.
modificationProtectionReason String
The reason why the configuration read-only mode is enabled. The modification_protection_reason takes effect only when modification_protection_status is set to ConsoleProtection.
modificationProtectionStatus String
Specifies whether to enable the configuration read-only mode. Default value: NonProtection. Valid values:

  • NonProtection: Does not enable the configuration read-only mode. You cannot set the modification_protection_reason. If the modification_protection_reason is set, the value is cleared.
  • ConsoleProtection: Enables the configuration read-only mode. You can set the modification_protection_reason.
paymentType Changes to this property will trigger replacement. String
The payment type of the resource
regionId String
The ID of the region where the NLB instance is deployed.
resourceGroupId String
The ID of the new resource group. You can log on to the Resource Management console to view resource group IDs.
securityGroupIds List<String>
The security group to which the network-based SLB instance belongs.
status String
Zone Status
tags Map<String>
List of labels.
vpcId Changes to this property will trigger replacement. String
The ID of the VPC where the NLB instance is deployed.
zoneMappings List<Property Map>
Available Area Configuration List. You must add at least two zones. You can add a maximum of 10 zones. See zone_mappings below.

Supporting Types

LoadBalancerDeletionProtectionConfig
, LoadBalancerDeletionProtectionConfigArgs

Enabled bool
Specifies whether to enable deletion protection. Valid values:
EnabledTime string
Opening time of the configuration read-only mode.
Reason string

The reason why deletion protection is enabled. The reason must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The reason must start with a letter.

NOTE: This parameter takes effect only when DeletionProtectionEnabled is set to true.

Enabled bool
Specifies whether to enable deletion protection. Valid values:
EnabledTime string
Opening time of the configuration read-only mode.
Reason string

The reason why deletion protection is enabled. The reason must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The reason must start with a letter.

NOTE: This parameter takes effect only when DeletionProtectionEnabled is set to true.

enabled Boolean
Specifies whether to enable deletion protection. Valid values:
enabledTime String
Opening time of the configuration read-only mode.
reason String

The reason why deletion protection is enabled. The reason must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The reason must start with a letter.

NOTE: This parameter takes effect only when DeletionProtectionEnabled is set to true.

enabled boolean
Specifies whether to enable deletion protection. Valid values:
enabledTime string
Opening time of the configuration read-only mode.
reason string

The reason why deletion protection is enabled. The reason must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The reason must start with a letter.

NOTE: This parameter takes effect only when DeletionProtectionEnabled is set to true.

enabled bool
Specifies whether to enable deletion protection. Valid values:
enabled_time str
Opening time of the configuration read-only mode.
reason str

The reason why deletion protection is enabled. The reason must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The reason must start with a letter.

NOTE: This parameter takes effect only when DeletionProtectionEnabled is set to true.

enabled Boolean
Specifies whether to enable deletion protection. Valid values:
enabledTime String
Opening time of the configuration read-only mode.
reason String

The reason why deletion protection is enabled. The reason must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The reason must start with a letter.

NOTE: This parameter takes effect only when DeletionProtectionEnabled is set to true.

LoadBalancerModificationProtectionConfig
, LoadBalancerModificationProtectionConfigArgs

EnabledTime string
Opening time of the configuration read-only mode.
Reason string

The reason why the configuration read-only mode is enabled. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.

NOTE: This parameter takes effect only if the status parameter is set to ConsoleProtection.

Status string

Specifies whether to enable the configuration read-only mode. Valid values:

  • NonProtection: disables the configuration read-only mode. In this case, you cannot set the ModificationProtectionReason parameter. If you specify ModificationProtectionReason, the value is cleared.
  • ConsoleProtection: enables the configuration read-only mode. In this case, you can specify ModificationProtectionReason.

NOTE: If you set this parameter to ConsoleProtection, you cannot use the NLB console to modify instance configurations. However, you can call API operations to modify instance configurations.

EnabledTime string
Opening time of the configuration read-only mode.
Reason string

The reason why the configuration read-only mode is enabled. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.

NOTE: This parameter takes effect only if the status parameter is set to ConsoleProtection.

Status string

Specifies whether to enable the configuration read-only mode. Valid values:

  • NonProtection: disables the configuration read-only mode. In this case, you cannot set the ModificationProtectionReason parameter. If you specify ModificationProtectionReason, the value is cleared.
  • ConsoleProtection: enables the configuration read-only mode. In this case, you can specify ModificationProtectionReason.

NOTE: If you set this parameter to ConsoleProtection, you cannot use the NLB console to modify instance configurations. However, you can call API operations to modify instance configurations.

enabledTime String
Opening time of the configuration read-only mode.
reason String

The reason why the configuration read-only mode is enabled. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.

NOTE: This parameter takes effect only if the status parameter is set to ConsoleProtection.

status String

Specifies whether to enable the configuration read-only mode. Valid values:

  • NonProtection: disables the configuration read-only mode. In this case, you cannot set the ModificationProtectionReason parameter. If you specify ModificationProtectionReason, the value is cleared.
  • ConsoleProtection: enables the configuration read-only mode. In this case, you can specify ModificationProtectionReason.

NOTE: If you set this parameter to ConsoleProtection, you cannot use the NLB console to modify instance configurations. However, you can call API operations to modify instance configurations.

enabledTime string
Opening time of the configuration read-only mode.
reason string

The reason why the configuration read-only mode is enabled. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.

NOTE: This parameter takes effect only if the status parameter is set to ConsoleProtection.

status string

Specifies whether to enable the configuration read-only mode. Valid values:

  • NonProtection: disables the configuration read-only mode. In this case, you cannot set the ModificationProtectionReason parameter. If you specify ModificationProtectionReason, the value is cleared.
  • ConsoleProtection: enables the configuration read-only mode. In this case, you can specify ModificationProtectionReason.

NOTE: If you set this parameter to ConsoleProtection, you cannot use the NLB console to modify instance configurations. However, you can call API operations to modify instance configurations.

enabled_time str
Opening time of the configuration read-only mode.
reason str

The reason why the configuration read-only mode is enabled. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.

NOTE: This parameter takes effect only if the status parameter is set to ConsoleProtection.

status str

Specifies whether to enable the configuration read-only mode. Valid values:

  • NonProtection: disables the configuration read-only mode. In this case, you cannot set the ModificationProtectionReason parameter. If you specify ModificationProtectionReason, the value is cleared.
  • ConsoleProtection: enables the configuration read-only mode. In this case, you can specify ModificationProtectionReason.

NOTE: If you set this parameter to ConsoleProtection, you cannot use the NLB console to modify instance configurations. However, you can call API operations to modify instance configurations.

enabledTime String
Opening time of the configuration read-only mode.
reason String

The reason why the configuration read-only mode is enabled. The value must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The value must start with a letter.

NOTE: This parameter takes effect only if the status parameter is set to ConsoleProtection.

status String

Specifies whether to enable the configuration read-only mode. Valid values:

  • NonProtection: disables the configuration read-only mode. In this case, you cannot set the ModificationProtectionReason parameter. If you specify ModificationProtectionReason, the value is cleared.
  • ConsoleProtection: enables the configuration read-only mode. In this case, you can specify ModificationProtectionReason.

NOTE: If you set this parameter to ConsoleProtection, you cannot use the NLB console to modify instance configurations. However, you can call API operations to modify instance configurations.

LoadBalancerZoneMapping
, LoadBalancerZoneMappingArgs

VswitchId This property is required. string
The vSwitch in the zone. You can specify only one vSwitch (subnet) in each zone of an NLB instance. You must add at least two zones. You can add a maximum of 10 zones.
ZoneId This property is required. string
The ID of the zone of the NLB instance. You must add at least two zones. You can add a maximum of 10 zones. You can call the DescribeZones operation to query the most recent zone list.
AllocationId string
The ID of the elastic IP address (EIP) that is associated with the Internet-facing NLB instance. You can specify one EIP for each zone. You must add at least two zones. You can add a maximum of 10 zones.
EniId string
The ID of the elastic network interface (ENI).
Ipv4LocalAddresses List<string>
IPv4 Local address list. The list of addresses that NLB interacts with backend services.
Ipv6Address string
The IPv6 address of the NLB instance.
Ipv6LocalAddresses List<string>
IPv6 Local address list. The list of addresses that NLB interacts with backend services.
PrivateIpv4Address string
The private IP address. You must add at least two zones. You can add a maximum of 10 zones.
PublicIpv4Address string
The public IPv4 address of the NLB instance.
Status string
Zone Status
VswitchId This property is required. string
The vSwitch in the zone. You can specify only one vSwitch (subnet) in each zone of an NLB instance. You must add at least two zones. You can add a maximum of 10 zones.
ZoneId This property is required. string
The ID of the zone of the NLB instance. You must add at least two zones. You can add a maximum of 10 zones. You can call the DescribeZones operation to query the most recent zone list.
AllocationId string
The ID of the elastic IP address (EIP) that is associated with the Internet-facing NLB instance. You can specify one EIP for each zone. You must add at least two zones. You can add a maximum of 10 zones.
EniId string
The ID of the elastic network interface (ENI).
Ipv4LocalAddresses []string
IPv4 Local address list. The list of addresses that NLB interacts with backend services.
Ipv6Address string
The IPv6 address of the NLB instance.
Ipv6LocalAddresses []string
IPv6 Local address list. The list of addresses that NLB interacts with backend services.
PrivateIpv4Address string
The private IP address. You must add at least two zones. You can add a maximum of 10 zones.
PublicIpv4Address string
The public IPv4 address of the NLB instance.
Status string
Zone Status
vswitchId This property is required. String
The vSwitch in the zone. You can specify only one vSwitch (subnet) in each zone of an NLB instance. You must add at least two zones. You can add a maximum of 10 zones.
zoneId This property is required. String
The ID of the zone of the NLB instance. You must add at least two zones. You can add a maximum of 10 zones. You can call the DescribeZones operation to query the most recent zone list.
allocationId String
The ID of the elastic IP address (EIP) that is associated with the Internet-facing NLB instance. You can specify one EIP for each zone. You must add at least two zones. You can add a maximum of 10 zones.
eniId String
The ID of the elastic network interface (ENI).
ipv4LocalAddresses List<String>
IPv4 Local address list. The list of addresses that NLB interacts with backend services.
ipv6Address String
The IPv6 address of the NLB instance.
ipv6LocalAddresses List<String>
IPv6 Local address list. The list of addresses that NLB interacts with backend services.
privateIpv4Address String
The private IP address. You must add at least two zones. You can add a maximum of 10 zones.
publicIpv4Address String
The public IPv4 address of the NLB instance.
status String
Zone Status
vswitchId This property is required. string
The vSwitch in the zone. You can specify only one vSwitch (subnet) in each zone of an NLB instance. You must add at least two zones. You can add a maximum of 10 zones.
zoneId This property is required. string
The ID of the zone of the NLB instance. You must add at least two zones. You can add a maximum of 10 zones. You can call the DescribeZones operation to query the most recent zone list.
allocationId string
The ID of the elastic IP address (EIP) that is associated with the Internet-facing NLB instance. You can specify one EIP for each zone. You must add at least two zones. You can add a maximum of 10 zones.
eniId string
The ID of the elastic network interface (ENI).
ipv4LocalAddresses string[]
IPv4 Local address list. The list of addresses that NLB interacts with backend services.
ipv6Address string
The IPv6 address of the NLB instance.
ipv6LocalAddresses string[]
IPv6 Local address list. The list of addresses that NLB interacts with backend services.
privateIpv4Address string
The private IP address. You must add at least two zones. You can add a maximum of 10 zones.
publicIpv4Address string
The public IPv4 address of the NLB instance.
status string
Zone Status
vswitch_id This property is required. str
The vSwitch in the zone. You can specify only one vSwitch (subnet) in each zone of an NLB instance. You must add at least two zones. You can add a maximum of 10 zones.
zone_id This property is required. str
The ID of the zone of the NLB instance. You must add at least two zones. You can add a maximum of 10 zones. You can call the DescribeZones operation to query the most recent zone list.
allocation_id str
The ID of the elastic IP address (EIP) that is associated with the Internet-facing NLB instance. You can specify one EIP for each zone. You must add at least two zones. You can add a maximum of 10 zones.
eni_id str
The ID of the elastic network interface (ENI).
ipv4_local_addresses Sequence[str]
IPv4 Local address list. The list of addresses that NLB interacts with backend services.
ipv6_address str
The IPv6 address of the NLB instance.
ipv6_local_addresses Sequence[str]
IPv6 Local address list. The list of addresses that NLB interacts with backend services.
private_ipv4_address str
The private IP address. You must add at least two zones. You can add a maximum of 10 zones.
public_ipv4_address str
The public IPv4 address of the NLB instance.
status str
Zone Status
vswitchId This property is required. String
The vSwitch in the zone. You can specify only one vSwitch (subnet) in each zone of an NLB instance. You must add at least two zones. You can add a maximum of 10 zones.
zoneId This property is required. String
The ID of the zone of the NLB instance. You must add at least two zones. You can add a maximum of 10 zones. You can call the DescribeZones operation to query the most recent zone list.
allocationId String
The ID of the elastic IP address (EIP) that is associated with the Internet-facing NLB instance. You can specify one EIP for each zone. You must add at least two zones. You can add a maximum of 10 zones.
eniId String
The ID of the elastic network interface (ENI).
ipv4LocalAddresses List<String>
IPv4 Local address list. The list of addresses that NLB interacts with backend services.
ipv6Address String
The IPv6 address of the NLB instance.
ipv6LocalAddresses List<String>
IPv6 Local address list. The list of addresses that NLB interacts with backend services.
privateIpv4Address String
The private IP address. You must add at least two zones. You can add a maximum of 10 zones.
publicIpv4Address String
The public IPv4 address of the NLB instance.
status String
Zone Status

Import

Network Load Balancer (NLB) Load Balancer can be imported using the id, e.g.

$ pulumi import alicloud:nlb/loadBalancer:LoadBalancer example <id>
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
Alibaba Cloud pulumi/pulumi-alicloud
License
Apache-2.0
Notes
This Pulumi package is based on the alicloud Terraform Provider.