Note: The list of features may not be up-to-date. For accurate command details, type azure | azure -h | azure --help to navigate through the help system. Also, use azure config mode asm|arm to switch between service management (Version V1)and resource management (Version V2) of the Azure REST API.

Endpoints for Azure

The CLI targets "Public Azure Cloud" by default. You can get more information about the endpoints supported in different environments from here.

Non-Interactive Authentication

If you need to create an automation account for non interactive or scripting scenarios then please take a look at the documentation over here.

Supported Environment Variables

Please take a look at the list of supported environment variables over here.

Installation

Installation from a particular branch of this repository

Uninstall the previously installed CLI

If you installed via MSI, then uninstall the windows MSI. For mac installer sudo azure-uninstall -g

If you installed via npm then execute: npm uninstall -g azure-cli

Clear the global cache:

If npm4.0 or before: npm cache clear -g

If npm5.0 or greater npm cache verify

Delete the .streamline folder from the User’s home profile C:\Users\<username>\.streamline | ~/.streamline, if present.

Download the tarball from this link: https://github.com/Azure/azure-xplat-cli/archive/<branch-name>.tar.gz

Install from the tarball: npm install –g <path to the downloaded tarball>

And you should be good to go :).
Note: You may require admin prompt or sudo access to install via npm.

Installation from npm

You can install the azure-cli npm package directly.

npm install -g azure-cli

Installing the latest version of node.js on different linux flavors

This document provides simple steps to install the latest version of node.js on a linux system. After successful installation of node.js, you can install "azure-cli" via npm as decribed above.

Installation on a Docker Host

In a Docker host, run:

sudo docker run -it microsoft/azure-cli

You can clone the repo and use the "Dockerfile" from master branch. It should install the last released version of azure-cli.

If you use both mechanisms on the same subscription, Azure Active Directory authentication will be used by default. If you want to go back to management certificate authentication, please use azure logout, which will remove the Azure Active Directory information and bring management certificate authentication back in.

Docker

This command only supports Ubuntu 14.04+ and CoreOS based images. Docker is configured on the VM using HTTPS as described here: https://docs.docker.com/articles/https/ By default, generated TLS certificates are placed in the ~/.docker directory, and Docker is configured to run on port 2376. These can be configured using new options:

Contribute Code or Provide Feedback

Please send pull requests only to the Dev branch. Please make sure that you have checked in tests and recorded them live for your contribution. Pull requests without sufficient tests will not be accepted.

If you encounter any bugs with the library please file an issue in the Issues section of the project.