deleteTargetGroups

Prev Next

VPC環境で利用できます。

ターゲットグループを削除します。使用中のターゲットグループは削除できません。

構文

deleteTargetGroups構文は次の通りです。

./ncloud vloadbalancer deleteTargetGroups \
    --targetGroupNoList <target-group-no-list> \
    [--regionCode <KR|SGN|JPN>] \
    [--output <json|xml>]

オプション

deleteTargetGroupsの実行時に指定できるオプションについて説明します。

必須オプション

deleteTargetGroupsの必須オプションです。

オプション タイプ 必須の有無 説明
--targetGroupNoList List Required ターゲットグループの番号リスト
  • スペースで区切って複数入力可能 (例: --targetGroupNoList 55667788 55667799)
  • getTargetGroupListを参照

共通オプション

vloadbalancerコマンドで共通して使用するオプションについては、Load Balancer (VPC)のオプションをご参照ください。

例

ターゲットグループの削除リクエストが成功すると、削除されたターゲットグループの構成情報が返されます。

コマンド

コマンドの例は次の通りです。

./ncloud vloadbalancer deleteTargetGroups \
    --targetGroupNoList 55667799 \
    --regionCode KR \
    --output json

出力

出力の例は次の通りです。

{
  "deleteTargetGroupsResponse": {
    "totalRows": 1,
    "targetGroupList": [
      {
        "targetGroupNo": "55667799",
        "targetGroupName": "lb-test-tg2",
        "targetType": {
          "code": "VSVR",
          "codeName": "Server (VPC)"
        },
        "vpcNo": "12345678",
        "targetGroupProtocolType": {
          "code": "HTTP",
          "codeName": "HTTP protocol"
        },
        "targetGroupPort": 80,
        "targetGroupDescription": "",
        "useStickySession": false,
        "useProxyProtocol": false,
        "algorithmType": {
          "code": "RR",
          "codeName": "Round Robin"
        },
        "createDate": "2026-07-07T17:12:57+0900",
        "regionCode": "KR",
        "loadBalancerInstanceNo": "",
        "healthCheckProtocolType": {
          "code": "HTTP",
          "codeName": "HTTP protocol"
        },
        "healthCheckPort": 80,
        "healthCheckUrlPath": "/",
        "healthCheckHttpMethodType": {
          "code": "GET",
          "codeName": "HTTP GET Method"
        },
        "healthCheckCycle": 30,
        "healthCheckUpThreshold": 2,
        "healthCheckDownThreshold": 2,
        "targetNoList": []
      }
    ],
    "requestId": "e1f2a3b4-c5d6-7890-efab-123456789012",
    "returnCode": "0",
    "returnMessage": "success"
  }
}