We help IT Professionals succeed at work.

Mapping Azure Storage drive automatically

klsphotos
klsphotos asked
on
141 Views
Last Modified: 2018-04-10
Hi Experts,

I have a Azure Storage Folder Share and have successfully mapped it to my windows system here at the office and also on our RDS server out in Azure.  I have tested and saved a document to it and can see it on the RDS server.  Works beautifully.

I did this by adding a mapped drive and entering in the credentials and password key of the share.

How can I do this automatically?  

In group policy the "connect as" is greyed out.  When I created a powershell script and ran it it didn't work.

I want the users who log into the RDS server to have this drive show available to them and I want selected users here at the office to have the same drive available to them.  

Thank you,

Karen
Comment
Watch Question

Jose Gabriel Ortega CastroCEO Faru Bonon IT&Agency /Top-Rated Freelancer (Upwork)/Photographer
CERTIFIED EXPERT
Awarded 2018
Distinguished Expert 2018

Commented:
What if you do a bat file.

net use Z:\  \\(azuredrive)  /u:<azureuser> /pwd
And save it into the Start up scripts on the computers (local policy).

Or just Following this script

$acctKey = ConvertTo-SecureString -String "<storage-account-key>" -AsPlainText -Force
$credential = New-Object System.Management.Automation.PSCredential -ArgumentList "Azure\<storage-account-name>", $acctKey
New-PSDrive -Name <desired-drive-letter> -PSProvider FileSystem -Root "\\<storage-account-name>.file.core.windows.net\<share-name>" -Credential $credential

Open in new window


that is in the documentation (https://docs.microsoft.com/en-us/azure/storage/files/storage-how-to-use-files-windows)

I mean setting it as startup script by user on the rdp policies or local policies.
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION
Seth SimmonsLead Systems Administrator
CERTIFIED EXPERT

Commented:
No comment has been added to this question in more than 21 days, so it is now classified as abandoned.

I have recommended this question be closed as follows:

Accept: klsphotos (https:#a42479179)

If you feel this question should be closed differently, post an objection and the moderators will review all objections and close it as they feel fit. If no one objects, this question will be closed automatically the way described above.

seth2740
Experts-Exchange Cleanup Volunteer
Unlock the solution to this question.
Join our community and discover your potential

Experts Exchange is the only place where you can interact directly with leading experts in the technology field. Become a member today and access the collective knowledge of thousands of technology experts.

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.