-
Notifications
You must be signed in to change notification settings - Fork 2
QueueStorage
Tore Nestenius edited this page Nov 22, 2024
·
10 revisions
This tools allows you to send and receive messages from a given Azure Queue Storage queue.
To set up Azure Queue Storage for testing and development, follow these steps.
- In the Azure Portal, search for and create a new Storage Account:
-
Name: Choose a unique name, e.g.,
clouddebuggerstorage
- Primary Service: Select Azure Blob Storage
- Performance: Choose Standard
- Redundancy: Set to Locally-Redundant Storage (LRS) for cost-effective testing.
-
Name: Choose a unique name, e.g.,
- Click Create to finalize the setup.
- Within your newly created storage account, navigate to Queues and select + Queue to create a new queue:
-
Name: Enter a unique name, e.g.,
mystoragequeue
-
Name: Enter a unique name, e.g.,
- Click OK to create the queue.
- In the Azure portal, go to your storage account and select the queue you just created.
- Copy the URL to the queue. This URL will be needed to connect your application to this queue.
The tool supports two methods for authenticating access to Azure Queue Storage:
- SAS Token: Using a a Shared Access Signature (SAS) token with specific permissions.
- Managed Identity: Authenticate using a managed identity assigned.
To create a SAS token with limited permissions for secure access:
-
In the Azure Portal, navigate to your Storage Account.
-
Under Security + networking, select Shared access signature.
-
Configure the SAS token settings:
- Allowed Services: Select Queue.
- Allowed Resource Types: Select Service, Container, and Object.
- Allowed Permissions: Select Read, Add, and Process Messages.
- Expiry: Set an expiration date and time for the SAS token.
-
Click Generate SAS and connection string.
-
Copy the SAS Token from the generated results.
Note: Always store the SAS token securely, as they grant specific access rights to the queue.
To enable access to the queue using a managed identity, follow these steps:
- Navigate to your Azure Queue in the Azure Portal.
- Select Access Control (IAM) from the left-hand menu.
- Click Add role assignment.
- Choose an appropriate role for the Cloud Debugger managed identity:
- Storage Queue Data Contributor: Provides full access to manage queues and messages.
- Storage Queue Data Message Processor: Grants permissions to read and delete messages.
- Storage Queue Data Message Sender: Allows sending messages to the queue.
- Storage Queue Data Reader: Allows read-only access to messages in the queue.
- Assign the selected role to the Cloud Debugger managed identity to enable it to interact with the queue as specified.