question

StefanovaVeselaIOCPDLTQ-0812 avatar image
0 Votes"
StefanovaVeselaIOCPDLTQ-0812 asked deherman-MSFT answered

Assign role Storage Contributor to a VM with Java SDK

Hello all, I am currently writing a Java program that creates a VM and wants to download a file from a storage into the VM. Therefore I need to assign access to the VM with role Storage blob data contributor. However, I cannot seem to be able to find how this is possible with the Java SDK (I found the RoleAssignment Documentation, but there are no examples). Can someone point me to the right direction or provide me with an example code snippet?

azure-virtual-machinesazure-storage-accounts
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

deherman-MSFT avatar image
0 Votes"
deherman-MSFT answered

@StefanovaVeselaIOCPDLTQ-0812
There is a sample available here which I believe is what you are looking for. You will probably find the REST API example helpful to better understand some of the terms.

Hope this helps. Let us know if you need further assistance or have further questions.



Please don’t forget to "Accept the answer" and “up-vote” wherever the information provided helps you, this can be beneficial to other community members.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.