- 09 Dec 2025
- 3 Minutes to read
- Print
- DarkLight
Azure
- Updated on 09 Dec 2025
- 3 Minutes to read
- Print
- DarkLight
The Azure CLI is a set of commands used to create and manage Azure resources. With this component of the Cloud CLI Extension, you can interact with Azure directly from LimaCharlie.
This extension makes use of the Azure CLI, which can be found here.
Configuration
Creating the App Registration
Sign in to the Entra Admin Center at https://entra.microsoft.com/
Copy the
Tenant IDto a text editor to use laterGo to Entra ID → App Registrations and select New Registration
Give the app a name
Under Supported account types, select Accounts in this organizational directory only
Click Register to create the app registration
Copy the
Application (client) IDto a text editor to use later
Creating the Client Secret
In the left sidebar menu of the Azure Portal, click Certificates & secrets
Click Client secrets, and then select New client secret
Enter a description of the secret and set an expiration date
It is recommended to set this value to as long as your policy allows. When the secret expires, LimaCharlie will no longer be able to interact with your cloud environment.
Click Add to add the new client secret
Copy the secret located in the
Valuecolumn to a text editor to use laterThe client secret can only be viewed once. When you navigate away from the page, the secret will no longer be available and will need to be recreated if not saved.
Assigning Roles to the App
In the Azure search bar located at the top of the screen, search for Subscriptions and click on Subscriptions from the search results
In the left menu, click Access control (IAM)
Click Add and then select Add Role Assignment
In the Role tab, select the roles to apply to the application and then click Next
This will control the actions available to LimaCharlie, so ensure any actions you wish to perform with LimaCharlie are included in the roles assigned.
On the Members tab, under the Assign access to section, select User, group, or service principal.
Click Select Members and then search for the app you created in step #3
By default, Microsoft Entra applications aren't displayed in the available options. To find your application, search for it by name.
Click the Select button and then click Review + Assign to assign the roles and subscription to your app
Adding the Secret to LimaCharlie
Log in to LimaCharlie at https://app.limacharlie.io
Open your organization
On the left menu, click on Organization Settings and click Secrets Manager
Give the secret a name
Enter the secret in the following format:
Application ID/Client Secret/Tenant IDNote that each ID is separated by a / character.
Example:
c0ff33ab-1337-b33f-2bad-f1234f1234ab/2nH9Q~l2TobhppdHbdoyClq6jjS9wWz~9.__Jb12/l0l4b33f-1234-4321-abcd-d34db33faf4b
Testing the Cloud CLI
From the left menu in LimaCharlie, click Extensions
Click on Cloud CLI
Click the Secrets Manager toggle and then select the secret you previously created from the dropdown
Under Tool, select az
In the Command Line box, enter the following command to verify authentication is working correctly:
versionYou should get a response similar to the following:
{ "azure-cli": "2.75.0", "azure-cli-core": "2.75.0", "azure-cli-telemetry": "1.1.0", "extensions": {} }If the
versioncommand succeeded, verify you are able to perform tasks within the environment by entering the following command to list all VMs:vm list —output jsonYou should get a response similar to the following:
[ { "additionalCapabilities": { "hibernationEnabled": false }, "billingProfile": { "maxPrice": -1 }, "diagnosticsProfile": { "bootDiagnostics": { "enabled": true } }, "etag": "\"2\"", "evictionPolicy": "Deallocate", "hardwareProfile": { "vmSize": "Standard_DS1_v2" }, ---SNIP---
Your configuration is now complete and Cloud CLI commands can be used in D&R rules.
Example
The following example returns a list of virtual machines and their respective details in Azure.
- action: extension request
extension action: run
extension name: ext-cloud-cli
extension request:
cloud: '{{ "az" }}'
command_line: '{{ "vm list" }}'
credentials: '{{ "hive://secret/secret-name" }}'
Credentials
To utilize the Azure CLI, you will need:
An application and a service principal with the appropriate permissions and a client secret
Create a secret in the secrets manager in the following format:
appID/clientSecret/tenantID