Class LoadBalancer
Inherited Members
Namespace: Pulumi.AliCloud.Slb
Assembly: Pulumi.AliCloud.dll
Syntax
public class LoadBalancer : CustomResource
Constructors
View SourceLoadBalancer(String, LoadBalancerArgs, CustomResourceOptions)
Create a LoadBalancer resource with the given unique name, arguments, and options.
Declaration
public LoadBalancer(string name, LoadBalancerArgs args = null, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| LoadBalancerArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceAddress
Specify the IP address of the private network for the SLB instance, which must be in the destination CIDR block of the correspond ing switch.
Declaration
public Output<string> Address { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
AddressIpVersion
The IP version of the SLB instance to be created, which can be set to ipv4 or ipv6 . Default to "ipv4". Now, only internet instance support ipv6 address.
Declaration
public Output<string> AddressIpVersion { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
AddressType
The network type of the SLB instance. Valid values: ["internet", "intranet"]. If load balancer launched in VPC, this value must be "intranet".
- internet: After an Internet SLB instance is created, the system allocates a public IP address so that the instance can forward requests from the Internet.
- intranet: After an intranet SLB instance is created, the system allocates an intranet IP address so that the instance can only forward intranet requests.
Declaration
public Output<string> AddressType { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Bandwidth
Valid value is between 1 and 1000, If argument "internet_charge_type" is "paybytraffic", then this value will be ignore.
Declaration
public Output<int?> Bandwidth { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Nullable<System.Int32>> |
DeleteProtection
Whether enable the deletion protection or not. on: Enable deletion protection. off: Disable deletion protection. Default to off. Only postpaid instance support this function.
Declaration
public Output<string> DeleteProtection { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
InstanceChargeType
The billing method of the load balancer. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".
Declaration
public Output<string> InstanceChargeType { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Internet
Field 'internet' has been deprecated from provider version 1.55.3. Use 'address_type' replaces it.
Declaration
public Output<bool> Internet { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Boolean> |
InternetChargeType
Valid
values are PayByBandwidth, PayByTraffic. If this value is "PayByBandwidth", then argument "internet" must be "true". Default is "PayByTraffic". If load balancer launched in VPC, this value must be "PayByTraffic".
Before version 1.10.1, the valid values are "paybybandwidth" and "paybytraffic".
Declaration
public Output<string> InternetChargeType { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
MasterZoneId
The primary zone ID of the SLB instance. If not specified, the system will be randomly assigned. You can query the primary and standby zones in a region by calling the DescribeZone API.
Declaration
public Output<string> MasterZoneId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Name
Declaration
public Output<string> Name { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Period
The duration that you will buy the resource, in month. It is valid when instance_charge_type is PrePaid. Default to 1. Valid values: [1-9, 12, 24, 36].
Declaration
public Output<int?> Period { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Nullable<System.Int32>> |
ResourceGroupId
The Id of resource group which the SLB belongs.
Declaration
public Output<string> ResourceGroupId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
SlaveZoneId
The standby zone ID of the SLB instance. If not specified, the system will be randomly assigned. You can query the primary and standby zones in a region by calling the DescribeZone API.
Declaration
public Output<string> SlaveZoneId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Specification
The specification of the Server Load Balancer instance. Default to empty string indicating it is "Shared-Performance" instance. Launching "Performance-guaranteed" instance, it is must be specified and it valid values are: "slb.s1.small", "slb.s2.small", "slb.s2.medium", "slb.s3.small", "slb.s3.medium", "slb.s3.large" and "slb.s4.large".
Declaration
public Output<string> Specification { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Tags
A mapping of tags to assign to the resource. The tags can have a maximum of 10 tag for every load balancer instance.
Declaration
public Output<ImmutableDictionary<string, object>> Tags { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Collections.Immutable.ImmutableDictionary<System.String, System.Object>> |
VswitchId
The VSwitch ID to launch in. If address_type is internet, it will be ignore.
Declaration
public Output<string> VswitchId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Methods
View SourceGet(String, Input<String>, LoadBalancerState, CustomResourceOptions)
Get an existing LoadBalancer resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static LoadBalancer Get(string name, Input<string> id, LoadBalancerState state = null, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resulting resource. |
| Input<System.String> | id | The unique provider ID of the resource to lookup. |
| LoadBalancerState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| LoadBalancer |