Home > Blockchain >  Create SFTP Local User to Azure storage account using Powershell
Create SFTP Local User to Azure storage account using Powershell

Time:05-25

I'm using Runbooks and wanted to utilize a PowerShell script to establish an SFTP local user for an Azure Storage Account. I found an article that has all steps but this is using the Az.Storage 4.1.2-Preview. but I am using the latest version of the Az.Storage which is 4.5.0

Article: https://docs.microsoft.com/en-us/azure/storage/blobs/secure-file-transfer-protocol-support-how-to?tabs=powershell

In the above article, we are using the "New-AzStorageLocalUserPermissionScope" command but this is not available in the latest version of Az.Storage Module.

Did any face this issue earlier?

CodePudding user response:

I just checked in the latest preview version Az.Storage 4.4.2-preview and the SFTP commands are present in the latest preview.

I would assume that this is due to the SFTP Storage account functionality still being in public preview. When the service is made generally available the Az.Storage module would be updated with the new commands!

You could have both versions installed in the automation account and implicitly specify the preview version for the runbook to create users:

https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/import-module?view=powershell-7.2#example-11-import-using-a-fully-qualified-name

  • Related