通过 powershell 创建 SASToken 时,它会从 New-AzureStorageContainerSASToken comdlet 返回创建的 SAS token URL。
$Context = New-AzureStorageContext -StorageAccountName $StorageAccount -StorageAccountKey $StorageAccountKey
$now = Get-Date
$sasUrl = New-AzureStorageContainerSASToken -Name mycontainer -Permission rwdl -StartTime $now.AddHours(-1) -ExpiryTime $now.AddMonths(1) -Context $context -FullUri
echo $sasUrl
但现在万一我丢失了它,如何列出现有的 SASToken?同一个容器中可能有几个。
尝试了 Get-AzureStorageContainer 但此信息不可用。
尝试过其他 Get-AzureStorage* 但未能找到它。
powershell 支持此操作吗?
最佳答案
无法获取 SAS URL 列表,因为它们没有存储在 Azure 存储中的任何位置。
关于powershell - 使用 Azure powershell 列出容器上的现有 SASToken,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34411220/