Skip to content

[Key Vault] az keyvault: Revise --id argument help text#20369

Merged
evelyn-ys merged 1 commit intoAzure:devfrom
chwarr:keyvault-id-is-url
Nov 17, 2021
Merged

[Key Vault] az keyvault: Revise --id argument help text#20369
evelyn-ys merged 1 commit intoAzure:devfrom
chwarr:keyvault-id-is-url

Conversation

@chwarr
Copy link
Member

@chwarr chwarr commented Nov 16, 2021

Description

For commands that use the --id argument to identify the vault/HSM, the
vault/HSM's full URI, like https://vault-name.vault.azure.net/, needs
to be passed, not the resource's ARM ID, like
/subscriptions/.../resourceGroups/.../providers/Microsoft.KeyVault/vaults/vault-name.

Refine the argument help text to use "Full URI" instead of "Id" to try
to minimize confusion.

Testing Guide

This only changes help text. No functionality should be affected.

Fixes #17399


This checklist is used to make sure that common guidelines for a pull request are followed.

**Description**

For commands that use the `--id` argument to identify the vault/HSM, the
vault/HSM's full URI, like `https://vault-name.vault.azure.net/`, needs
to be passed, not the resource's ARM ID, like
`/subscriptions/.../resourceGroups/.../providers/Microsoft.KeyVault/vaults/vault-name`.

Refine the argument help text to use "Full URI" instead of "Id" to try
to minimize confusion.

**Testing Guide**

This only changes help text. No functionality should be affected.

Fixes Azure#17399
@chwarr
Copy link
Member Author

chwarr commented Nov 16, 2021

Based on the discussion in issue #17399, "az keyvault certificate list --id", it appears that operations on the vault/HSM that have an --id parameter take the vault/HSM's full URI, not its ARM id. Let me know if any of the commands I've changed do not follow that pattern, and I can update.

@yonzhan
Copy link
Collaborator

yonzhan commented Nov 16, 2021

Key Vault

@evelyn-ys
Copy link
Member

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 2 pipeline(s).

if cmd in ['list']:
c.extra('identifier', options_list=['--id'],
help='Id of the Vault or HSM. '
help='Full URI of the Vault or HSM. '
Copy link
Member

@jiasli jiasli Nov 17, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Personally I think it is anti-convention to name it "URI" in Azure Portal (#17399 (comment)), given it has https:// prefix.

This was discussed previously at #13067.

Also see https://danielmiessler.com/study/difference-between-uri-url/

If the protocol (https, ftp, etc.) is either present or implied for a domain, you should call it a URL—even though it’s also a URI.

@evelyn-ys evelyn-ys merged commit 65c7868 into Azure:dev Nov 17, 2021
@chwarr chwarr deleted the keyvault-id-is-url branch November 17, 2021 18:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

az keyvault certificate list --id

4 participants