共用方式為


az appservice kube

Note

This reference is part of the appservice-kube extension for the Azure CLI (version 2.60.0 or higher). 當您第一次執行 az appservice kube 命令時,擴充功能會自動安裝。 Learn more about extensions.

此命令群組處於預覽狀態,且正在開發中。 參考和支援層級: https://aka.ms/CLI_refstatus

管理 Kubernetes 環境。

命令

名稱 Description 類型 狀態
az appservice kube create

建立 Kubernetes 環境。

Extension Preview
az appservice kube delete

刪除 kubernetes 環境。

Extension Preview
az appservice kube list

依訂用帳戶或資源群組列出 kubernetes 環境。

Extension Preview
az appservice kube show

顯示 kubernetes 環境的詳細數據。

Extension Preview
az appservice kube update

更新 Kubernetes 環境。 目前不支援。

Extension Preview
az appservice kube wait

等候 Kubernetes 環境達到所需的狀態。

Extension Preview

az appservice kube create

預覽

命令群組 『appservice kube』 處於預覽狀態,且正在開發中。 參考和支援層級: https://aka.ms/CLI_refstatus

建立 Kubernetes 環境。

az appservice kube create --custom-location
                          --name
                          --resource-group
                          [--location]
                          [--no-wait]
                          [--static-ip]
                          [--tags]

範例

使用相同資源群組中的自定義位置建立 Kubernetes 環境

az appservice kube create -n MyKubeEnvironment -g MyResourceGroup --static-ip 0.0.0.0 --custom-location custom_location_name

建立 Kubernetes 環境

az appservice kube create -n MyKubeEnvironment -g MyResourceGroup --static-ip 0.0.0.0 --custom-location /subscriptions/sub_id/resourcegroups/group_name/providers/microsoft.extendedlocation/customlocations/custom_location_name

必要參數

--custom-location -c

自定義位置的識別碼。

--name -n

kubernetes 環境的名稱。

--resource-group -g

資源組名。 您可以使用 az configure --defaults group=<name>來設定預設群組。

選擇性參數

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--location -l

Location. 值的來源:az account list-locations。 您可以使用 az configure --defaults location=<location>來設定預設位置。

--no-wait

請勿等候建立完成,並在佇列建立之後立即返回。

屬性
預設值: False
--static-ip

靜態IP位址。 如果指定 AKS 資源識別碼,則需要此識別碼。

--tags

以空格分隔的標記:key[=value] [key[=value] ...]。使用 「清除現有的標記」。

全域參數
--debug

提高日誌詳細程度以顯示所有調試日誌。

屬性
預設值: False
--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

屬性
預設值: False
--output -o

Output format.

屬性
預設值: json
接受的值: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID來設定預設訂用帳戶。

--verbose

增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。

屬性
預設值: False

az appservice kube delete

預覽

命令群組 『appservice kube』 處於預覽狀態,且正在開發中。 參考和支援層級: https://aka.ms/CLI_refstatus

刪除 kubernetes 環境。

az appservice kube delete --name
                          --resource-group
                          [--no-wait]
                          [--yes]

範例

刪除 Kubernetes 環境。

az appservice kube delete -g MyResourceGroup -n MyKubeEnvironment

必要參數

--name -n

Kubernetes 環境的名稱。

--resource-group -g

資源組名。 您可以使用 az configure --defaults group=<name>來設定預設群組。

選擇性參數

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--no-wait

請勿等候長時間執行的作業完成。

屬性
預設值: False
--yes -y

請勿提示確認。

屬性
預設值: False
全域參數
--debug

提高日誌詳細程度以顯示所有調試日誌。

屬性
預設值: False
--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

屬性
預設值: False
--output -o

Output format.

屬性
預設值: json
接受的值: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID來設定預設訂用帳戶。

--verbose

增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。

屬性
預設值: False

az appservice kube list

預覽

命令群組 『appservice kube』 處於預覽狀態,且正在開發中。 參考和支援層級: https://aka.ms/CLI_refstatus

依訂用帳戶或資源群組列出 kubernetes 環境。

az appservice kube list [--resource-group]

範例

依訂用帳戶列出 Kubernetes 環境。

az appservice kube list

依資源群組列出 Kubernetes 環境。

az appservice kube list -g MyResourceGroup

選擇性參數

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--resource-group -g

資源組名。 您可以使用 az configure --defaults group=<name>來設定預設群組。

全域參數
--debug

提高日誌詳細程度以顯示所有調試日誌。

屬性
預設值: False
--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

屬性
預設值: False
--output -o

Output format.

屬性
預設值: json
接受的值: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID來設定預設訂用帳戶。

--verbose

增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。

屬性
預設值: False

az appservice kube show

預覽

命令群組 『appservice kube』 處於預覽狀態,且正在開發中。 參考和支援層級: https://aka.ms/CLI_refstatus

顯示 kubernetes 環境的詳細數據。

az appservice kube show --name
                        --resource-group

範例

顯示 Kubernetes 環境的詳細數據。

az appservice kube show -n MyKubeEnvironment -g MyResourceGroup

必要參數

--name -n

Kubernetes 環境的名稱。

--resource-group -g

資源組名。 您可以使用 az configure --defaults group=<name>來設定預設群組。

全域參數
--debug

提高日誌詳細程度以顯示所有調試日誌。

屬性
預設值: False
--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

屬性
預設值: False
--output -o

Output format.

屬性
預設值: json
接受的值: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID來設定預設訂用帳戶。

--verbose

增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。

屬性
預設值: False

az appservice kube update

預覽

命令群組 『appservice kube』 處於預覽狀態,且正在開發中。 參考和支援層級: https://aka.ms/CLI_refstatus

更新 Kubernetes 環境。 目前不支援。

az appservice kube update --name
                          --resource-group
                          [--custom-location]
                          [--no-wait]
                          [--static-ip]
                          [--tags]

範例

更新 Kubernetes 環境

az appservice kube update --name MyKubeEnvironment -g MyResourceGroup --static-ip 0.0.0.0

必要參數

--name -n

kubernetes 環境的名稱。

--resource-group -g

資源組名。 您可以使用 az configure --defaults group=<name>來設定預設群組。

選擇性參數

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--custom-location -c

自定義位置的識別碼。

--no-wait

請勿等候長時間執行的作業完成。

屬性
預設值: False
--static-ip

新增靜態IP位址。

--tags

以空格分隔的標記:key[=value] [key[=value] ...]。使用 「清除現有的標記」。

全域參數
--debug

提高日誌詳細程度以顯示所有調試日誌。

屬性
預設值: False
--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

屬性
預設值: False
--output -o

Output format.

屬性
預設值: json
接受的值: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID來設定預設訂用帳戶。

--verbose

增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。

屬性
預設值: False

az appservice kube wait

預覽

命令群組 『appservice kube』 處於預覽狀態,且正在開發中。 參考和支援層級: https://aka.ms/CLI_refstatus

等候 Kubernetes 環境達到所需的狀態。

az appservice kube wait --name
                        --resource-group
                        [--created]
                        [--custom]
                        [--deleted]
                        [--exists]
                        [--interval]
                        [--timeout]
                        [--updated]

範例

等候布建 Kubernetes 環境,每隔 60 秒輪詢一次。

az appservice kube wait -g MyResourceGroup -n MyKubeEnvironment \
    --created --interval 60

必要參數

--name -n

Kubernetes 環境的名稱。

--resource-group -g

資源組名。 您可以使用 az configure --defaults group=<name>來設定預設群組。

選擇性參數

The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.

--created

請等候在 'Succeeded' 使用 'provisioningState' 建立。

屬性
Parameter group: Wait Condition Arguments
預設值: False
--custom

等到條件符合自定義 JMESPath 查詢為止。 例如 provisioningState!='InProgress', instanceView.statuses[?code=='PowerState/running']。

屬性
Parameter group: Wait Condition Arguments
--deleted

等到刪除為止。

屬性
Parameter group: Wait Condition Arguments
預設值: False
--exists

等候資源存在。

屬性
Parameter group: Wait Condition Arguments
預設值: False
--interval

輪詢間隔以秒為單位。

屬性
Parameter group: Wait Condition Arguments
預設值: 30
--timeout

以秒為單位的等候上限。

屬性
Parameter group: Wait Condition Arguments
預設值: 3600
--updated

等到 provisioningState 更新為 'Succeeded'。

屬性
Parameter group: Wait Condition Arguments
預設值: False
全域參數
--debug

提高日誌詳細程度以顯示所有調試日誌。

屬性
預設值: False
--help -h

顯示此說明訊息並結束。

--only-show-errors

只顯示錯誤,隱藏警告。

屬性
預設值: False
--output -o

Output format.

屬性
預設值: json
接受的值: json, jsonc, none, table, tsv, yaml, yamlc
--query

JMESPath 查詢字串。 如需詳細資訊和範例,請參閱 http://jmespath.org/

--subscription

訂用帳戶的名稱或標識碼。 您可以使用 az account set -s NAME_OR_ID來設定預設訂用帳戶。

--verbose

增加記錄的詳細程度。 針對完整偵錯記錄使用 --debug。

屬性
預設值: False