-
Notifications
You must be signed in to change notification settings - Fork 3.3k
Description
Hi.
There seems to be some kind of general bug somewhere in either VS code, gitbash or the az module.
Wherever resourceid for subnet is used the cli command will fail if it is run in VS code
The documentation states that --subnet is name or resource id...
When it comes to running this in CloudShell, it is correct, but in VS code it fails.
I have now tested with a storage account and a VM and same thing.
This is what happens:
SUBNET_ID=$(az network vnet subnet show --resource-group $VNET_RESOURCE_GROUP --name $SUBNET1 --vnet-name $VNET --query id -o tsv)
az storage account create \
--name $STORAGEACCOUNT_NAME \ --resource-group $SYNAPSE_RESOURCE_GROUP \ --location $REGION \ --sku Standard_LRS \ --kind StorageV2 \ --enable-hierarchical-namespace \ --min-tls-version TLS1_2 \ --subnet $SUBNET_ID
←[91mincorrect usage: [--subnet ID | --subnet NAME --vnet-name NAME]←[0m
And as I said, the same always works fine i CloudShell
(It is not the ID get that is the problem, that works. It makes no difference if I type or paste it in as a string)
Thanks
// Thomas Odell Balkeståhl
Dokumentinformation
⚠ Redigera inte det här avsnittet. Det krävs för docs.microsoft.com ➟ länkning till GitHub-problem.
- ID: 92115d19-d7a0-93a8-bf2b-5126d1cddcd0
- Version Independent ID: a657f09b-e1ac-12a2-4b9c-7aaa1f0e3f5c
- Content: az storage account
- Content Source: latest/docs-ref-autogen/storage/account.yml
- Service: storage
- GitHub Login: @rloutlaw
- Microsoft Alias: routlaw