az aks identity-binding
Note
This command group has commands that are defined in both Azure CLI and at least one extension. Install each extension to benefit from its extended capabilities. Learn more about extensions.
Commands to manage identity bindings in Azure Kubernetes Service.
Commands
| Name | Description | Type | Status |
|---|---|---|---|
| az aks identity-binding create |
Create a new identity binding in a managed Kubernetes cluster. |
Core | GA |
| az aks identity-binding create (aks-preview extension) |
Create a new identity binding in a managed Kubernetes cluster. |
Extension | GA |
| az aks identity-binding delete |
Delete a specific identity binding in a managed Kubernetes cluster. |
Core | GA |
| az aks identity-binding delete (aks-preview extension) |
Delete a specific identity binding in a managed Kubernetes cluster. |
Extension | GA |
| az aks identity-binding list |
List all identity bindings under a managed Kubernetes cluster. |
Core | GA |
| az aks identity-binding list (aks-preview extension) |
List all identity bindings under a managed Kubernetes cluster. |
Extension | GA |
| az aks identity-binding show |
Show details of a specific identity binding in a managed Kubernetes cluster. |
Core | GA |
| az aks identity-binding show (aks-preview extension) |
Show details of a specific identity binding in a managed Kubernetes cluster. |
Extension | GA |
| az aks identity-binding update |
Update an existing identity binding in a managed Kubernetes cluster. |
Extension | GA |
az aks identity-binding create
Create a new identity binding in a managed Kubernetes cluster.
az aks identity-binding create --cluster-name
--managed-identity-resource-id
--name
--resource-group
[--acquire-policy-token]
[--change-reference]
[--no-wait]
Examples
Create a new identity binding
az aks identity-binding create -g myResourceGroup --cluster-name myCluster -n myIdentityBinding --managed-identity-resource-id /subscriptions/0000/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/myIdentity
Required Parameters
Name of the managed Kubernetes cluster.
The resource ID of the managed identity to use.
Name of the identity binding to create.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Acquiring an Azure Policy token automatically for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
The related change reference ID for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
Do not wait for the long-running operation to finish.
| Property | Value |
|---|---|
| Default value: | False |
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az aks identity-binding create (aks-preview extension)
Create a new identity binding in a managed Kubernetes cluster.
az aks identity-binding create --cluster-name
--managed-identity-resource-id
--name
--resource-group
[--acquire-policy-token]
[--allowed-subjects-from-file]
[--change-reference]
Examples
Create an identity binding with allowed subjects targeting specific namespaces by name.
az aks identity-binding create --resource-group myRG --cluster-name myCluster \
--name my-identity-binding \
--managed-identity-resource-id /subscriptions/.../userAssignedIdentities/myMI \
--allowed-subjects-from-file allowed-subjects.json
Required Parameters
Name of the managed Kubernetes cluster.
The resource ID of the managed identity to use.
Name of the identity binding to create.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Acquiring an Azure Policy token automatically for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
Path to a JSON file with the list of subjects authorized to use this identity binding for token exchange.
The file must contain a JSON array (max 100 entries). Each entry has a required 'namespaceSelector' and an optional 'serviceAccountSelector', each a Kubernetes label selector supporting 'matchLabels' (an array of "key=value" strings) and/or 'matchExpressions'. Use the built-in 'kubernetes.io/metadata.name' label to target specific namespaces by name. When omitted, authorization falls back to ClusterRole/ClusterRoleBinding evaluation.
The related change reference ID for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az aks identity-binding delete
Delete a specific identity binding in a managed Kubernetes cluster.
az aks identity-binding delete --cluster-name
--name
--resource-group
[--acquire-policy-token]
[--change-reference]
[--no-wait]
[--yes]
Examples
Delete an identity binding
az aks identity-binding delete -g myResourceGroup --cluster-name myCluster -n myIdentityBinding
Required Parameters
Name of the managed Kubernetes cluster.
Name of the identity binding to delete.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Acquiring an Azure Policy token automatically for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
The related change reference ID for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
Do not wait for the long-running operation to finish.
| Property | Value |
|---|---|
| Default value: | False |
Do not prompt for confirmation.
| Property | Value |
|---|---|
| Default value: | False |
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az aks identity-binding delete (aks-preview extension)
Delete a specific identity binding in a managed Kubernetes cluster.
az aks identity-binding delete --cluster-name
--name
--resource-group
[--acquire-policy-token]
[--change-reference]
Required Parameters
Name of the managed Kubernetes cluster.
Name of the identity binding to delete.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Acquiring an Azure Policy token automatically for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
The related change reference ID for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az aks identity-binding list
List all identity bindings under a managed Kubernetes cluster.
az aks identity-binding list --cluster-name
--resource-group
Examples
List all identity bindings in a managed cluster
az aks identity-binding list -g myResourceGroup --cluster-name myCluster
Required Parameters
Name of the managed Kubernetes cluster.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az aks identity-binding list (aks-preview extension)
List all identity bindings under a managed Kubernetes cluster.
az aks identity-binding list --cluster-name
--resource-group
Required Parameters
Name of the managed Kubernetes cluster.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az aks identity-binding show
Show details of a specific identity binding in a managed Kubernetes cluster.
az aks identity-binding show --cluster-name
--name
--resource-group
Examples
Show details of an identity binding
az aks identity-binding show -g myResourceGroup --cluster-name myCluster -n myIdentityBinding
Required Parameters
Name of the managed Kubernetes cluster.
Name of the identity binding to show.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az aks identity-binding show (aks-preview extension)
Show details of a specific identity binding in a managed Kubernetes cluster.
az aks identity-binding show --cluster-name
--name
--resource-group
Required Parameters
Name of the managed Kubernetes cluster.
Name of the identity binding to show.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |
az aks identity-binding update
Update an existing identity binding in a managed Kubernetes cluster.
az aks identity-binding update --allowed-subjects-from-file
--cluster-name
--name
--resource-group
[--acquire-policy-token]
[--change-reference]
Examples
Update the allowed subjects on an existing identity binding.
az aks identity-binding update --resource-group myRG --cluster-name myCluster \
--name my-identity-binding \
--allowed-subjects-from-file updated-subjects.json
Required Parameters
Path to a JSON file with the list of subjects authorized to use this identity binding for token exchange.
The file must contain a JSON array (max 100 entries). Each entry has a required 'namespaceSelector' and an optional 'serviceAccountSelector', each a Kubernetes label selector supporting 'matchLabels' (an array of "key=value" strings) and/or 'matchExpressions'. Use the built-in 'kubernetes.io/metadata.name' label to target specific namespaces by name. Providing this replaces the existing allowed subjects list.
Name of the managed Kubernetes cluster.
Name of the identity binding to update.
Name of resource group. You can configure the default group using az configure --defaults group=<name>.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Acquiring an Azure Policy token automatically for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
The related change reference ID for this resource operation.
| Property | Value |
|---|---|
| Parameter group: | Global Policy Arguments |
Global Parameters
Increase logging verbosity to show all debug logs.
| Property | Value |
|---|---|
| Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
| Property | Value |
|---|---|
| Default value: | False |
Output format.
| Property | Value |
|---|---|
| Default value: | json |
| Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.
Increase logging verbosity. Use --debug for full debug logs.
| Property | Value |
|---|---|
| Default value: | False |