Is there a python function to retrieve a blob storage account connection string?
- If so, how is this accomplished?
- If not, is there a way to retrieve a SAS token using
az cliorpython?
Thank you
If using CLI is an option, you can get connection string for a storage account by using az storage account show-connection-string command.
az storage account show-connection-string --name MyStorageAccount --resource-group MyResourceGroup --subscription MySubscription
To get Shared Access Signature for a blob, you can use az storage blob generate-sas command.
end=`date -u -d "30 minutes" '+%Y-%m-%dT%H:%MZ'`
az storage blob generate-sas -c myycontainer -n MyBlob --permissions r --expiry $end --https-only
get connection string azure blob storage python sdk yields no relevant results where get connection string azure blob storage azure cli lead me to the resources you suggest. Thank you!func azure storage fetch-connection-string <StorageAccountName>. In case this is useful to someone. [1]: learn.microsoft.com/en-us/azure/azure-functions/…
notebooks.azure.com. I can't find a way to determine the SDK version. Regarding code, I've looked through all the samples mentioned here: learn.microsoft.com/en-us/samples/azure/azure-sdk-for-python/…. They all BEGIN with the connection string. I want to programmatically get it, not visit the azure portal gui. Is this possible?