HTTPS リスナーを作成します。
操作説明
新しく作成されたリスナーは stopped 状態です。リスナーを作成した後、StartLoadBalancerListener 操作を呼び出してリスナーを開始できます。リスナーが開始されると、リスナーはバックエンドサーバーにトラフィックを転送できます。
前提条件
Classic Load Balancer (CLB) インスタンスが作成されていること。詳細については、「CreateLoadBalancer」をご参照ください。
今すぐお試しください
テスト
RAM 認証
|
アクション |
アクセスレベル |
リソースタイプ |
条件キー |
依存アクション |
|
slb:CreateLoadBalancerHTTPSListener |
create |
*acl
*certificate
*loadbalancer
|
|
なし |
リクエストパラメーター
|
パラメーター |
型 |
必須 / 任意 |
説明 |
例 |
| RegionId |
string |
任意 |
CLB インスタンスのリージョン ID。 リージョン ID は、リージョンとゾーンのリストからクエリするか、DescribeRegions 操作を呼び出すことで取得できます。 |
cn-hangzhou |
| LoadBalancerId |
string |
必須 |
CLB インスタンスの ID。 |
lb-bp1o94dp5i6earr**** |
| Bandwidth |
integer |
必須 |
リスナーの最大帯域幅。単位:Mbit/s。 URL は次の要件を満たす必要があります:
|
-1 |
| ListenerPort |
integer |
必須 |
CLB インスタンスが使用するフロントエンドポート。 有効な値:1~65535。 |
80 |
| BackendServerPort |
integer |
任意 |
CLB インスタンスが使用するバックエンドポート。有効な値:1~65535。 VServerGroupId パラメーターが設定されていない場合、このパラメーターは必須です。 |
80 |
| Tag |
array<object> |
任意 |
タグ。 |
|
|
object |
任意 |
タグ。 |
||
| Key |
string |
任意 |
リソースのタグキー。最大 20 個のタグキーを指定できます。 タグキーは空の文字列にすることはできません。タグキーは 1~64 文字で、 |
TestKey |
| Value |
string |
任意 |
リソースのタグ値。最大 20 個のタグ値を指定できます。タグ値は空の文字列にすることはできません。 タグ値は最大 128 文字で、 |
TestValue |
| XForwardedFor |
string |
任意 |
|
on |
| Scheduler |
string |
任意 |
スケジューリングアルゴリズム。有効な値:
|
wrr |
| StickySession |
string |
任意 |
セッション維持を有効にするかどうかを指定します。有効な値:
|
on |
| StickySessionType |
string |
任意 |
Cookie を処理するために使用されるメソッド。有効な値:insert および server。
説明
このパラメーターは、StickySession パラメーターが on に設定されている場合に必須です。 |
insert |
| CookieTimeout |
integer |
任意 |
Cookie のタイムアウト期間。単位:秒。 有効な値:1~86400。 説明
StickySession が on に設定され、StickySessionType が insert に設定されている場合、このパラメーターは必須です。 |
500 |
| Cookie |
string |
任意 |
サーバー用に設定する Cookie。 Cookie は 1~200 文字で、ASCII 文字と数字のみを含めることができます。カンマ (,)、セミコロン (;)、スペースを含めることはできず、ドル記号 ($) で始めることはできません。 説明
このパラメーターは、StickySession パラメーターが on に設定され、StickySessionType パラメーターが server に設定されている場合に必須です。 |
B490B5EBF6F3CD402E515D22BCDA**** |
| HealthCheck |
string |
必須 |
ヘルスチェック機能を有効にするかどうかを指定します。有効な値:
|
on |
| HealthCheckMethod |
string |
任意 |
HTTP ヘルスチェックで使用されるヘルスチェックメソッド。有効な値:head および get。 説明
このパラメーターは、HealthCheck パラメーターが on に設定されている場合にのみ有効です。 |
get |
| HealthCheckDomain |
string |
任意 |
ヘルスチェックに使用されるドメイン名。有効な値:
説明
このパラメーターは、HealthCheck パラメーターが on に設定されている場合にのみ有効です。 |
172.XX.XX.16 |
| HealthCheckURI |
string |
任意 |
ヘルスチェックに使用される URI。 URI は 1~80 文字で、文字、数字、および次の特殊文字を含めることができます: 説明
このパラメーターは、HealthCheck パラメーターが on に設定されている場合にのみ有効です。 |
/test/index.html |
| HealthyThreshold |
integer |
任意 |
異常なバックエンドサーバーが正常と判断されるまでに連続してヘルスチェックに合格する必要がある回数。この場合、ヘルスステータスは fail から success に変更されます。 有効な値:2~10。 説明
このパラメーターは、HealthCheck パラメーターが on に設定されている場合にのみ有効です。 |
4 |
| UnhealthyThreshold |
integer |
任意 |
正常なバックエンドサーバーが異常と判断されるまでに連続してヘルスチェックに失敗する必要がある回数。この場合、ヘルスステータスは success から fail に変更されます。 有効な値:2~10。 説明
このパラメーターは、HealthCheck パラメーターが on に設定されている場合にのみ有効です。 |
4 |
| HealthCheckTimeout |
integer |
任意 |
ヘルスチェック応答のタイムアウト期間。バックエンドの ECS インスタンスが指定されたタイムアウト期間内に応答しない場合、ECS インスタンスはヘルスチェックに失敗します。単位:秒。有効な値:1~300。 説明
このパラメーターは、HealthCheck パラメーターが on に設定されている場合にのみ有効です。 |
3 |
| HealthCheckConnectPort |
integer |
任意 |
ヘルスチェックに使用されるポート。 有効な値:1~65535。 説明
このパラメーターは、HealthCheck パラメーターが on に設定されている場合にのみ有効です。 |
8080 |
| HealthCheckInterval |
integer |
任意 |
2 つの連続したヘルスチェックの間隔。単位:秒。 有効な値:1~50。 説明
このパラメーターは、HealthCheck パラメーターが on に設定されている場合にのみ有効です。 |
5 |
| HealthCheckHttpCode |
string |
任意 |
ヘルスチェックが成功した場合の HTTP ステータスコード。複数の HTTP ステータスコードはカンマ (,) で区切ります。 有効な値:http_2xx、http_3xx、http_4xx、および http_5xx。 説明
このパラメーターは、HealthCheck パラメーターが on に設定されている場合にのみ有効です。 |
http_2xx,http_3xx |
| ServerCertificateId |
string |
任意 |
サーバー証明書の ID。 |
idkp-123-cn-test-**** |
| VServerGroupId |
string |
任意 |
サーバーグループの ID。 |
rsp-cige6j5e7p**** |
| CACertificateId |
string |
任意 |
認証局 (CA) 証明書の ID。 CA 証明書とサーバー証明書の両方がアップロードされている場合、相互認証が使用されます。 サーバー証明書のみをアップロードした場合、一方向認証が使用されます。 |
139a00604ad-cn-east-hangzh**** |
| XForwardedFor_SLBIP |
string |
任意 |
|
on |
| XForwardedFor_SLBID |
string |
任意 |
|
on |
| XForwardedFor_proto |
string |
任意 |
|
on |
| Gzip |
string |
任意 |
特定の種類のファイルを圧縮するために
|
on |
| AclId |
string |
任意 |
リスナーに関連付けられているネットワークアクセス制御リスト (ACL) の ID。 説明
AclStatus が on に設定されている場合、このパラメーターは必須です。 |
nacl-a2do9e413e0spzasx**** |
| AclType |
string |
任意 |
ネットワーク ACL のタイプ。有効な値:
説明
AclStatus が on に設定されている場合、このパラメーターは必須です。 |
white |
| AclStatus |
string |
任意 |
アクセスの制御を有効にするかどうかを指定します。有効な値:
|
off |
| Description |
string |
任意 |
リスナーの名前。 名前は 1~256 文字で、文字、数字、ハイフン (-)、スラッシュ (/)、ピリオド (.)、アンダースコア (_) を含めることができます。 |
HTTPS_443 |
| IdleTimeout |
integer |
任意 |
アイドル接続のタイムアウト期間。有効な値:1~60。デフォルト値:15。単位:秒。 指定されたタイムアウト期間内にリクエストが受信されない場合、CLB は接続を閉じます。リクエストが受信されると、CLB は新しい接続を確立します。 |
12 |
| RequestTimeout |
integer |
任意 |
リクエストのタイムアウト期間。有効な値:1~180。デフォルト値:60。単位:秒。 指定されたタイムアウト期間内にバックエンドサーバーから応答がない場合、CLB はクライアントに HTTP 504 ステータスコードを返します。 |
23 |
| EnableHttp2 |
string |
任意 |
HTTP/2 を有効にするかどうかを指定します。有効な値:
|
off |
| TLSCipherPolicy |
string |
任意 |
Transport Layer Security (TLS) セキュリティポリシー。各セキュリティポリシーには、HTTPS で利用可能な TLS プロトコルバージョンと暗号スイートが含まれています。
|
tls_cipher_policy_1_1 |
| XForwardedFor_SLBPORT |
string |
任意 |
|
off |
| XForwardedFor_ClientSrcPort |
string |
任意 |
|
off |
レスポンスフィールド
|
フィールド |
型 |
説明 |
例 |
|
object |
|||
| RequestId |
string |
リクエストの ID。 |
CEF72CEB-54B6-4AE8-B225-F876FF7BA984 |
例
成功レスポンス
JSONJSON
{
"RequestId": "CEF72CEB-54B6-4AE8-B225-F876FF7BA984"
}
エラーコード
|
HTTP ステータスコード |
エラーコード |
エラーメッセージ |
説明 |
|---|---|---|---|
| 400 | ParamDuplicateError | The specified parameter value of XForwardedFor_ClientCertSubjectDNAlias is duplicate. Please change to a different one. | |
| 400 | IpVersionConflict | The ip version of this LoadBalancer and the Acl is conflict. | |
| 400 | InvalidParameter.IdleTimeout | The specified IdleTimeout exceeds the limit. | |
| 400 | InvalidParameter.RequestTimeout | The specified RequestTimeout exceeds the limit. | |
| 400 | ListenerForwardNotSupport | X-Forward-For is not supported to a ipv6 instance. | |
| 400 | InvalidParameter.RegionNotSupport | The region does not support the parameter: %s. | |
| 400 | InvalidParameter.SpecNotSupport | The loadBalancer of shared spec does not support the parameter: %s. | |
| 400 | ListenerProcessing | A previous configuration of the listener is pending,please try again later. | |
| 400 | Certkey.Forbidden | The specified certkey is not owned by the current user. | |
| 400 | InvalidParameter.ListenerPortConflict | There is conflict listener port exists. | |
| 400 | ResourceNotAvailible.HttpsListener | The specified Zone did not have enough resource. | |
| 400 | AclNotExist | Acl does not exist. | |
| 400 | OperationUnsupported.CreateLoadBalancerLayer7Listener | The slb instance does not support create HTTP or HTTPS listener. | |
| 400 | InvalidParameter.VServerGroupId | The MasterSlaveServerGroup can not be attached to HTTP or HTTPS listener. | |
| 400 | MissingParam.HealthCheckDomain | The HealthCheckDomain is required when HealthCheckHttpVersion is http1.1. | |
| 400 | InvalidParameter.HealthCheckHttpVersion | The param HealthCheckHttpVersion is invalid. | |
| 400 | Duplicated.AclEntry | %s. | |
| 400 | CertificateNotExist | The specified CertificateId does not exist. | |
| 400 | OperationFailed.InsufficientResources | The loadbalancer does not support this operation because of insufficient resources. | |
| 400 | InvalidTLSPolicyId.NotExist | The specified TLS cipher policy does not exist. | |
| 400 | TLSPolicyConfiguring | The specified TLS cipher policy is configuring. | |
| 400 | TLSCipherPolicyVipRelationOverLimit | The number of listeners associated with a policy has exceeded. | |
| 400 | CertificateTypeMismatched | The certificate type does not match. | |
| 400 | MissingParam.ServerCertificates | Server certificates are required. | |
| 400 | TooManyCertificates | The number of certificates must not be greater than one. | |
| 400 | CnCertificateNotSupport | The cn certificate is not support. | |
| 400 | InvalidParam.CertificateBindingType | The param CertificateBindingType is invalid. | |
| 400 | InvalidParamSize.ServerCertificates | The size of param ServerCertificates is invalid. | |
| 400 | TooManyCertificates.ServerCertificates | The number of certificates must not be greater than one. | |
| 400 | SPEC_NOT_SUPPORT_PARAMETER | Share spec does not support the feature. | |
| 400 | LbNotSupportTcpssl | You cannot create a TCP SSL type listener for the specified load balancer. | |
| 400 | LbSupportTcpsslOnly | The specified load balancer supports TCP SSL type listener only. | |
| 400 | ListenerNotSupportRule | You cannot create a rule for the specified listener. | |
| 400 | Mismatch.SlbSpecTypeAndListenerProtocol | The SlbSpecType and ListenerProtocol are mismatched. | |
| 400 | InvalidParam.TagValue | %s. | |
| 400 | InvalidParam.TagKey | %s. | |
| 400 | SizeLimitExceeded.Tag | %s. | |
| 400 | MissingParam.TagKey | The param MissingParam.TagKey is missing. | |
| 400 | AclListenerOverLimit | This acl has reached the limit of binding to listeners. | |
| 400 | QuotaLimitExceeds.AclAttachedToListener | The number of Acl bound listeners has reached the quota limit | |
| 400 | QuotaLimitExceeds.TotalAclEntry | The number of Acl entries has reached the quota limit. | |
| 400 | QuotaLimitExceeds.AclListenerOverLimit | This acl has reached the limit of binding to listeners. | |
| 404 | ResourceNotFound.Certificate | The specified resource is not found. |
完全なリストについては、「エラーコード」をご参照ください。
変更履歴
完全なリストについては、「変更履歴」をご参照ください。