Class DomainExtension
HTTPS listeners of guaranteed-performance SLB support configuring multiple certificates, allowing you to forward requests with different domain names to different backend servers. Please refer to the documentation for details.
NOTE: Available in 1.60.0+
NOTE: The instance with shared loadBalancerSpec doesn't support domainExtension.
Example Usage
using Pulumi;
using AliCloud = Pulumi.AliCloud;
class MyStack : Stack
{
public MyStack()
{
var instance = new AliCloud.Slb.LoadBalancer("instance", new AliCloud.Slb.LoadBalancerArgs
{
Internet = "true",
InternetChargeType = "PayByTraffic",
});
var foo = new AliCloud.Slb.ServerCertificate("foo", new AliCloud.Slb.ServerCertificateArgs
{
PrivateKey = @"-----BEGIN RSA PRIVATE KEY-----
MIIEowIBAAKCAQEAyjCheapjf7qDI3R9w/Gj0XFDgNLPK2aWIRvM25BdY/IB2KAf
xQ7zOxu3X1bMo2zMCzsSrwIVrxx0qRM/7e4AfkHcKwDIjCcBprQp164dhFol4GpT
HtcuGv0+Ue6vpuE9cxQE3/pG5x1n5EhheFu2+lAaGh/vUrUPeQp6szX/9qfzn+/k
tF8wsRV8PBiFc2ZNMRXupRyc2qtOn95r86w/uK6TuerU1L64E2P5+tYLBWT+39Ai
diUIenjURThFEn8Srvw8v/iLEMaKwiWNkOfWQH96166gzddOI8PT5cJy5an2c90T
DgzegVo8RPK70bU9KjH7gH79YIwXVmTdIVGAUQIDAQABAoIBAE1J4a/8biR5S3/W
G+03BYQeY8tuyjqw8FqfoeOcf9agwAvqybouSNQjeCk9qOQfxq/UWQQFK/zQR9gJ
v7pX7GBXFK5rkj3g+0SaQhRsPmRFgY0Tl8qGPt2aSKRRNVv5ZeADmwlzRn86QmiF
Mp0rkfqFfDTYWEepZszCML0ouzuxsW/9tq7rvtSjsgATNt31B3vFa3D3JBi31jUh
5nfR9A3bATze7mQw3byEDiVl5ASRDgYyur403P1fDnMy9DBHZ8NaPOsFF6OBpJal
BJsG5z00hll5PFN2jfmBQKlvAeU7wfwqdaSnGHOfqf2DeTTaFjIQ4gUhRn/m6pLo
6kXttLECgYEA9sng0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jl1S9ZgdA6Zc=
-----END CERTIFICATE-----
",
});
var https = new AliCloud.Slb.Listener("https", new AliCloud.Slb.ListenerArgs
{
BackendPort = 80,
Bandwidth = 10,
Cookie = "testslblistenercookie",
CookieTimeout = 86400,
FrontendPort = 443,
HealthCheck = "on",
HealthCheckConnectPort = 20,
HealthCheckHttpCode = "http_2xx,http_3xx",
HealthCheckInterval = 5,
HealthCheckTimeout = 8,
HealthCheckUri = "/cons",
HealthyThreshold = 8,
LoadBalancerId = instance.Id,
Protocol = "https",
SslCertificateId = foo.Id,
StickySession = "on",
StickySessionType = "insert",
UnhealthyThreshold = 8,
});
var example1 = new AliCloud.Slb.DomainExtension("example1", new AliCloud.Slb.DomainExtensionArgs
{
Domain = "www.test.com",
FrontendPort = https.FrontendPort,
LoadBalancerId = instance.Id,
ServerCertificateId = foo.Id,
});
}
}
Inherited Members
Namespace: Pulumi.AliCloud.Slb
Assembly: Pulumi.AliCloud.dll
Syntax
public class DomainExtension : CustomResource
Constructors
View SourceDomainExtension(String, DomainExtensionArgs, CustomResourceOptions)
Create a DomainExtension resource with the given unique name, arguments, and options.
Declaration
public DomainExtension(string name, DomainExtensionArgs args, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| DomainExtensionArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceDeleteProtectionValidation
Checking DeleteProtection of SLB instance before deleting. If true, this resource will not be deleted when its SLB instance enabled DeleteProtection. Default to false.
Declaration
public Output<bool?> DeleteProtectionValidation { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Nullable<System.Boolean>> |
Domain
The domain name,
Declaration
public Output<string> Domain { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
FrontendPort
The frontend port used by the HTTPS listener of the SLB instance. Valid values: 1–65535.
Declaration
public Output<int> FrontendPort { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Int32> |
LoadBalancerId
The ID of the SLB instance.
Declaration
public Output<string> LoadBalancerId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
ServerCertificateId
The ID of the certificate used by the domain name.
Declaration
public Output<string> ServerCertificateId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Methods
View SourceGet(String, Input<String>, DomainExtensionState, CustomResourceOptions)
Get an existing DomainExtension resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static DomainExtension Get(string name, Input<string> id, DomainExtensionState 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. |
| DomainExtensionState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| DomainExtension |