Announcing template-based previews of Azure CLI and Azure PowerShell for Key Vault deployments
We are announcing the new implementation of Azure CLI and Azure PowerShell commands to create Azure Key Vault.
Advantages
We leverage the ARM template mechanism to refactor the Key Vault command line. Compared with the previous implementation, calling REST API through SDKs, this implementation scheme has the following advantages that users can benefit from.
- Consistency. Ensure consistent behavior and defaults between Azure CLI, Azure PowerShell, and Portal.
- What-If. Support a ‘what if’ option to predict the impact of a deployment before the command is executed.
- Idempotency. Sending the same request multiple times will produce the same result, regardless of resource state.
What’s new
We implemented several new features when compared to the previous version of commands.
What-If
What-If is designed to show users as much information about what their deployment will do before it deploys.
Progress Bar
We have implemented a progress bar to visualize the deployment.
Idempotency
We are using the incremental mode of ARM deployment to create key vaults. By setting –FailOnExist as $false, we can repeatedly create the same key vault or update the existing one.
Create a same key vault
Update the existing vault
Deep Dive
For Key Vault creation, Azure Client Tools previously followed a different structure than Azure Portal, as shown in the following example:
With the ARM template included, we maintain consistency and communicate directly with ARM:
We are using template specs to make staging and sharing of ARM templates easy.
Next Steps
We look forward to your feedback. We will evaluate the effects and risks and consider expanding the command line scope of service, module, and extension.
Getting Started
You can test our new version by following the instructions provided below. Your feedback will help shape the strategy of how we build the command line tools for Azure.
Getting started with Azure PowerShell
The PowerShell package for private preview is provided on the PowerShell Gallery.
Installation
Copy and paste the following command to install this package using PowerShellGet:
Install-Module -Name Az.KeyVault -RequiredVersion 4.12.0-preview -AllowPrerelease
Quick Start
Getting started with Azure CLI
The CLI package for public preview is provided as MSI / whl packages:
For MSI package Installation
Download and install the MSI package. When the installer asks if it can make changes to your computer, select "Yes". If you have previously installed the Azure CLI, make sure it has been uninstalled first.
For whl package Installation
- Prepare and use a separate virtual environment
# Create a python virtual env named `testenv` with: python -m venv testenv # Activate the env (if you are using powershell): .\testenv\Scripts\Activate.ps1 # Activate the env (if you are using bash): source venv/bin/activate - Unzip and install private .whl packages
# Unzip the file and install three cli whl packages (azure_cli, azure_cli_core, azure_cli_telemetry) pip install azure_cli-2.53.0.post20230920063357-py3-none-any.whl azure_cli_core-2.53.0.post20230920063357-py3-none-any.whl azure_cli_telemetry-1.1.0.post20230920063357-py3-none-any.whl
Quick Start
For whl package clean up
Feedback
This feature is already available. Feel free to share your experience by participating in our survey. We welcome your feedback!
Published on:
Learn moreRelated posts
Episode 413 – Simplifying Azure Files with a new file share-centric management model
Welcome to Episode 413 of the Microsoft Cloud IT Pro Podcast. Microsoft has introduced a new file share-centric management model for Azure Fil...
Bringing Context to Copilot: Azure Cosmos DB Best Practices, Right in Your VS Code Workspace
Developers love GitHub Copilot for its instant, intelligent code suggestions. But what if those suggestions could also reflect your specific d...
Build an AI Agentic RAG search application with React, SQL Azure and Azure Static Web Apps
Introduction Leveraging OpenAI for semantic searches on structured databases like Azure SQL enhances search accuracy and context-awareness, pr...
Announcing latest Azure Cosmos DB Python SDK: Powering the Future of AI with OpenAI
We’re thrilled to announce the stable release of Azure Cosmos DB Python SDK version 4.14.0! This release brings together months of innov...
How Azure CLI handles your tokens and what you might be ignoring
Running az login feels like magic. A browser pops up, you pick an account, and from then on, everything just works. No more passwords, no more...
Boost your Azure Cosmos DB Efficiency with Azure Advisor Insights
Azure Cosmos DB is Microsoft’s globally distributed, multi-model database service, trusted for mission-critical workloads that demand high ava...
Microsoft Azure Fundamentals #5: Complex Error Handling Patterns for High-Volume Microsoft Dataverse Integrations in Azure
🚀 1. Problem Context When integrating Microsoft Dataverse with Azure services (e.g., Azure Service Bus, Azure Functions, Logic Apps, Azure SQ...
Using the Secret Management PowerShell Module with Azure Key Vault and Azure Automation
Automation account credential resources are the easiest way to manage credentials for Azure Automation runbooks. The Secret Management module ...
Microsoft Azure Fundamentals #4: Azure Service Bus Topics and Subscriptions for multi-system CRM workflows in Microsoft Dataverse / Dynamics 365
🚀 1. Scenario Overview In modern enterprise environments, a single business event in Microsoft Dataverse (CRM) can trigger workflows across m...
Easily connect AI workloads to Azure Blob Storage with adlfs
Microsoft works with the fsspec open-source community to enhance adlfs. This update delivers faster file operations and improved reliability f...