From 5a022906dcdc15b8a52e333b4c95d7ca2c85e16a Mon Sep 17 00:00:00 2001 From: jiasli <4003950+jiasli@users.noreply.github.com> Date: Fri, 8 Nov 2024 18:31:40 +0800 Subject: [PATCH] login-help --- src/azure-cli/HISTORY.rst | 2 +- src/azure-cli/azure/cli/command_modules/profile/_help.py | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/azure-cli/HISTORY.rst b/src/azure-cli/HISTORY.rst index db98a7577dc..09c3eb2d384 100644 --- a/src/azure-cli/HISTORY.rst +++ b/src/azure-cli/HISTORY.rst @@ -76,7 +76,7 @@ Release History **Profile** -* `az login`: Passing the service principal certificate with `--password` is deprecated and will be removed by version 2.74. Please use `--certificate` instead. (#30091) +* `az login`: Passing the service principal certificate with `--password` is deprecated and will be removed in version 2.67.0. Please use `--certificate` instead. (#30091) **RDBMS** diff --git a/src/azure-cli/azure/cli/command_modules/profile/_help.py b/src/azure-cli/azure/cli/command_modules/profile/_help.py index d3f5c3b9abe..3f5c1ead13d 100644 --- a/src/azure-cli/azure/cli/command_modules/profile/_help.py +++ b/src/azure-cli/azure/cli/command_modules/profile/_help.py @@ -36,11 +36,11 @@ - name: Log in interactively. text: az login - name: Log in with username and password. This doesn't work with Microsoft accounts or accounts that have two-factor authentication enabled. Use -p=secret if the first character of the password is '-'. - text: az login -u johndoe@contoso.com -p VerySecret - - name: Log in with a service principal using client secret. Use -p=secret if the first character of the password is '-'. - text: az login --service-principal -u http://azure-cli-2016-08-05-14-31-15 -p VerySecret --tenant contoso.onmicrosoft.com + text: az login --username johndoe@contoso.com --password VerySecret + - name: Log in with a service principal using client secret. Use --password=secret if the first character of the password is '-'. + text: az login --service-principal --username APP_ID --password CLIENT_SECRET --tenant TENANT_ID - name: Log in with a service principal using certificate. - text: az login --service-principal -u http://azure-cli-2016-08-05-14-31-15 --certificate ~/mycertfile.pem --tenant contoso.onmicrosoft.com + text: az login --service-principal --username APP_ID --certificate /path/to/cert.pem --tenant TENANT_ID - name: Log in with a system-assigned managed identity. text: az login --identity - name: Log in with a user-assigned managed identity. You must specify the client ID, object ID or resource ID of the user-assigned managed identity with --username.