I am using the Azure CLI to create a blob level user delegated SAS, using steps from this article.
I have hidden the name of my storage account for the purpose of this post.
The PowerShell az storage blob generate-sas
cmdlet is returning;
HTTPSConnectionPool(host='https', port=443): Max retries exceeded with url: //storeageAccountName.blob.core.windows.net?restype=service&comp=userdelegationkey (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known',))
and I noticed that the URL = //storeageAccountName.blob.core.windows.net, and not, https://storeageAccountName.blob.core.windows.net.
The PowerShell code:
$sasToken = az storage blob generate-sas `
--account-name $storageAccount `
--container-name $container `
--name $blob `
--permissions acdrw `
--expiry "2020-04-10T14:50Z" `
--auth-mode login `
--as-user `
--full-uri