text:
Extensibility: Command Hooks lib components

Adds command hook library components (Not wired up for e2e use)
Related to #1253
Included Features

Support for pre and post command hooks
Support for bash and powershell scripts
Support for explicit hooks to be defined within azure.yaml
Support for implicit hooks based on script files existing within the .azure/hooks directory
Support for OS specific overrides for Windows and Linux

Questions

Since linux and mac work essentially the same should we rename Linux to Posix or something else to denote that it applies for both?

Azure Dev CLI Install Instructions
Install scripts
MacOS/Linux

May elevate using sudo on some platforms and configurations

bash:
curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.sh | bash;
curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.sh | bash -s -- --base-url https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236 --version '' --verbose

pwsh:
Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.ps1' -OutFile uninstall-azd.ps1; ./uninstall-azd.ps1
Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.ps1' -OutFile install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236' -Version '' -Verbose

Windows
powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.ps1' > uninstall-azd.ps1; ./uninstall-azd.ps1;"
powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.ps1' > install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236' -Version '' -Verbose;"

Standalone Binary

Linux - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-linux-amd64.tar.gz
MacOS - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-darwin-amd64.zip
Windows - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.zip

Container
docker run -it azdevcliextacr.azurecr.io/azure-dev:pr-1236

Azure Dev CLI Install Instructions
Install scripts
MacOS/Linux

May elevate using sudo on some platforms and configurations

bash:
curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.sh | bash;
curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.sh | bash -s -- --base-url https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236 --version '' --verbose

pwsh:
Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.ps1' -OutFile uninstall-azd.ps1; ./uninstall-azd.ps1
Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.ps1' -OutFile install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236' -Version '' -Verbose

Windows
PowerShell install
powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.ps1' > uninstall-azd.ps1; ./uninstall-azd.ps1;"
powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.ps1' > install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236' -Version '' -Verbose;"

MSI install
powershell -c "irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.msi' -OutFile azd-windows-amd64.msi; msiexec /i azd-windows-amd64.msi /qn"

Standalone Binary

Linux - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-linux-amd64.tar.gz
MacOS - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-darwin-amd64.zip
Windows - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.zip

MSI

https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.msi

Container
docker run -it azdevcliextacr.azurecr.io/azure-dev:pr-1236

Documentation

learn.microsoft.com documentation

title: Azure Developer CLI Preview reference
description: This article explains the syntax and parameters for the various Azure Developer CLI Preview commands.
author: puichan
ms.author: puichan
ms.date: 01/06/23
ms.topic: conceptual
ms.custom: devx-track-azdevcli
ms.prod: azure
Azure Developer CLI Preview reference
This article explains the syntax and parameters for the various Azure Developer CLI Preview commands.
azd
Azure Developer CLI is a command-line interface for developers who build Azure solutions.
Synopsis
Azure Developer CLI is a command-line interface for developers who build Azure solutions.
To begin working with Azure Developer CLI, run the azd up command by supplying a sample template in an empty directory:
	azd up –-template todo-nodejs-mongo

You can pick a template by running azd template listand then supplying the repo name as a value to --template.
The most common next commands are:
	azd pipeline config
	azd deploy
	azd monitor --overview

For more information, visit the Azure Developer CLI Dev Hub: https://aka.ms/azure-dev/devhub.
Options
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
  -h, --help         Gets help for azd.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage Azure Developer CLI configuration
azd deploy: Deploy the application's code to Azure.
azd down: Delete Azure resources for an application.
azd env: Manage environments.
azd infra: Manage Azure resources.
azd init: Initialize a new application.
azd login: Log in to Azure.
azd logout: Log out of Azure
azd monitor: Monitor a deployed application.
azd pipeline: Manage GitHub Actions pipelines.
azd provision: Provision the Azure resources for an application.
azd restore: Restore application dependencies.
azd template: Manage templates.
azd up: Initialize application, provision Azure resources, and deploy your project with a single command.
azd version: Print the version number of Azure Developer CLI.

azd config
Manage Azure Developer CLI configuration
Synopsis
Manage the Azure Developer CLI user configuration, which includes your default Azure subscription and location.
The default value of the config directory is:

$HOME/.azd on Linux and MacOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
Options
  -h, --help   Gets help for config.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config get: Gets a configuration
azd config list: Lists all configuration values
azd config reset: Resets configuration to default
azd config set: Sets a configuration
azd config unset: Unsets a configuration
Back to top

azd config get
Gets a configuration
Synopsis
Gets a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and MacOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config get <path> [flags]

Options
  -h, --help            Gets help for get.
  -o, --output string   The output format (the supported formats are json). (default "json")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage Azure Developer CLI configuration
Back to top

azd config list
Lists all configuration values
Synopsis
Lists all configuration values in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and MacOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json). (default "json")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage Azure Developer CLI configuration
Back to top

azd config reset
Resets configuration to default
Synopsis
Resets all configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and MacOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable to the default.
azd config reset [flags]

Options
  -h, --help   Gets help for reset.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage Azure Developer CLI configuration
Back to top

azd config set
Sets a configuration
Synopsis
Sets a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and MacOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config set <path> <value> [flags]

Examples
azd config set defaults.subscription <yourSubscriptionID>
azd config set defaults.location eastus

Options
  -h, --help   Gets help for set.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage Azure Developer CLI configuration
Back to top

azd config unset
Unsets a configuration
Synopsis
Removes a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and MacOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config unset <path> [flags]

Examples
azd config unset defaults.location

Options
  -h, --help   Gets help for unset.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage Azure Developer CLI configuration
Back to top

azd deploy
Deploy the application's code to Azure.
Synopsis
Deploy the application's code to Azure.
When no --service value is specified, all services in the azure.yaml file (found in the root of your project) are deployed.
Examples:
	azd deploy
	azd deploy --service api
	azd deploy --service web

After the deployment is complete, the endpoint is printed. To start the service, select the endpoint or paste it in a browser.
azd deploy [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for deploy.
  -o, --output string        The output format (the supported formats are json, none). (default "none")
      --service string       Deploys a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are deployed).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd down
Delete Azure resources for an application.
azd down [flags]

Options
  -e, --environment string   The name of the environment to use.
      --force                Does not require confirmation before it deletes resources.
  -h, --help                 Gets help for down.
  -o, --output string        The output format (the supported formats are json, none). (default "none")
      --purge                Does not require confirmation before it permanently deletes resources that are soft-deleted by default (for example, key vaults).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd env
Manage environments.
Synopsis
Manage environments.
With this command group, you can create a new environment or get, set, and list your application environments. An application can have multiple environments (for example, dev, test, prod), each with a different configuration (that is, connectivity information) for accessing Azure resources.
You can find all environment configurations under the .azure<environment-name> folder. The environment name is stored as the AZURE_ENV_NAME environment variable in the .azure<environment-name>\folder.env file.
Options
  -h, --help   Gets help for env.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env get-values: Get all environment values.
azd env list: List environments
azd env new: Create a new environment.
azd env refresh: Refresh environment settings by using information from a previous infrastructure provision.
azd env select: Set the default environment.
azd env set: Set a value in the environment.
Back to top

azd env get-values
Get all environment values.
azd env get-values [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for get-values.
  -o, --output string        The output format (the supported formats are json, dotenv). (default "dotenv")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env list
List environments
azd env list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env new
Create a new environment.
azd env new <environment> [flags]

Options
  -h, --help                  Gets help for new.
  -l, --location string       Azure location for the new environment
      --subscription string   Name or ID of an Azure subscription to use for the new environment

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env refresh
Refresh environment settings by using information from a previous infrastructure provision.
azd env refresh [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for refresh.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env select
Set the default environment.
azd env select <environment> [flags]

Options
  -h, --help   Gets help for select.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env set
Set a value in the environment.
azd env set <key> <value> [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for set.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd infra
Manage Azure resources.
Options
  -h, --help   Gets help for infra.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra create: Create Azure resources for an application.
azd infra delete: Delete Azure resources for an application.
Back to top

azd infra create
Create Azure resources for an application.
azd infra create [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for create.
      --no-progress          Suppresses progress information.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra: Manage Azure resources.
Back to top

azd infra delete
Delete Azure resources for an application.
azd infra delete [flags]

Options
  -e, --environment string   The name of the environment to use.
      --force                Does not require confirmation before it deletes resources.
  -h, --help                 Gets help for delete.
      --purge                Does not require confirmation before it permanently deletes resources that are soft-deleted by default (for example, key vaults).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra: Manage Azure resources.
Back to top

azd init
Initialize a new application.
Synopsis
Initialize a new application.
When no template is supplied, you can optionally select an Azure Developer CLI template for cloning. Otherwise, azd init initializes the current directory and creates resources so that your project is compatible with Azure Developer CLI.
When a template is provided, the sample code is cloned to the current directory.
azd init [flags]

Options
  -b, --branch string         The template branch to initialize from.
  -e, --environment string    The name of the environment to use.
  -h, --help                  Gets help for init.
  -l, --location string       Azure location for the new environment
      --subscription string   Name or ID of an Azure subscription to use for the new environment
  -t, --template string       The template to use when you initialize the project. You can use Full URI, <owner>/<repository>, or <repository> if it's part of the azure-samples organization.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd login
Log in to Azure.
Synopsis
Log in to Azure.
When run without any arguments, log in interactively using a browser. To log in using a device code, pass
--device-code.
To log in as a service principal, pass --client-id and --tenant-id as well as one of --client-secret,
--client-certificate, --client-credential or --client-credential-provider.
azd login [flags]

Options
      --check-status                           Checks the log-in status instead of logging in.
      --client-certificate string              The path to the client certificate for the service principal to authenticate with.
      --client-id string                       The client id for the service principal to authenticate with.
      --client-secret string                   The client secret for the service principal to authenticate with. Set to the empty string to read the value from the console.
      --federated-credential string            The federated token for the service principal to authenticate with. Set to the empty string to read the value from the console.
      --federated-credential-provider string   The provider to use to acquire a federated token to authenticate with.
  -h, --help                                   Gets help for login.
  -o, --output string                          The output format (the supported formats are json, none). (default "none")
      --redirect-port int                      Choose the port to be used as part of the redirect URI during interactive login.
      --tenant-id string                       The tenant id for the service principal to authenticate with.
      --use-device-code                        When true, log in by using a device code instead of a browser.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd logout
Log out of Azure
Synopsis
Log out of Azure
azd logout [flags]

Options
  -h, --help   Gets help for logout.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd monitor
Monitor a deployed application.
Synopsis
Monitor a deployed application.
Examples:
	azd monitor --overview
	azd monitor -–live
	azd monitor --logs

For more information, go to https://aka.ms/azure-dev/monitor.
azd monitor [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for monitor.
      --live                 Open a browser to Application Insights Live Metrics. Live Metrics is currently not supported for Python applications.
      --logs                 Open a browser to Application Insights Logs.
      --overview             Open a browser to Application Insights Overview Dashboard.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd pipeline
Manage GitHub Actions pipelines.
Synopsis
Manage GitHub Actions pipelines.
The Azure Developer CLI template includes a GitHub Actions pipeline configuration file (in the .github/workflows folder) that deploys your application whenever code is pushed to the main branch.
For more information, go to https://aka.ms/azure-dev/pipeline.
Options
  -h, --help   Gets help for pipeline.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd pipeline config: Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
Back to top

azd pipeline config
Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
Synopsis
Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
For more information, go to https://aka.ms/azure-dev/pipeline.
azd pipeline config [flags]

Options
      --auth-type string        The authentication type used between the pipeline provider and Azure for deployment (Only valid for GitHub provider)
  -e, --environment string      The name of the environment to use.
  -h, --help                    Gets help for config.
      --principal-name string   The name of the service principal to use to grant access to Azure resources as part of the pipeline.
      --principal-role string   The role to assign to the service principal. (default "contributor")
      --provider string         The pipeline provider to use (github for Github Actions and azdo for Azure Pipelines). (default "github")
      --remote-name string      The name of the git remote to configure the pipeline to run on. (default "origin")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd pipeline: Manage GitHub Actions pipelines.
Back to top

azd provision
Provision the Azure resources for an application.
Synopsis
Provision the Azure resources for an application.
The command prompts you for the following:

Environment name: The name of your environment.
Azure location: The Azure location where your resources will be deployed.
Azure subscription: The Azure subscription where your resources will be deployed.

Depending on what Azure resources are created, running this command might take a while. To view progress, go to the Azure portal and search for the resource group that contains your environment name.
azd provision [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for provision.
      --no-progress          Suppresses progress information.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd restore
Restore application dependencies.
Synopsis
Restore application dependencies.
Run this command to download and install all the required libraries so that you can build, run, and debug the application locally.
For the best local run and debug experience, go to https://aka.ms/azure-dev/vscode to learn how to use the Visual Studio Code extension.
azd restore [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for restore.
      --service string       Restores a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are restored).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd template
Manage templates.
Options
  -h, --help   Gets help for template.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template list: List templates.
azd template show: Show the template details.
Back to top

azd template list
List templates.
azd template list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template: Manage templates.
Back to top

azd template show
Show the template details.
azd template show <template> [flags]

Options
  -h, --help            Gets help for show.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template: Manage templates.
Back to top

azd up
Initialize application, provision Azure resources, and deploy your project with a single command.
Synopsis
Initialize the project (if the project folder has not been initialized or cloned from a template), provision Azure resources, and deploy your project with a single command.
This command executes the following in one step:
	azd init
	azd provision
	azd deploy

When no template is supplied, you can optionally select an Azure Developer CLI template for cloning. Otherwise, running azd up initializes the current directory so that your project is compatible with Azure Developer CLI.
azd up [flags]

Options
  -b, --branch string         The template branch to initialize from.
  -e, --environment string    The name of the environment to use.
  -h, --help                  Gets help for up.
  -l, --location string       Azure location for the new environment
      --no-progress           Suppresses progress information.
  -o, --output string         The output format (the supported formats are json, none). (default "none")
      --service string        Deploys a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are deployed).
      --subscription string   Name or ID of an Azure subscription to use for the new environment
  -t, --template string       The template to use when you initialize the project. You can use Full URI, <owner>/<repository>, or <repository> if it's part of the azure-samples organization.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd version
Print the version number of Azure Developer CLI.
azd version [flags]

Options
  -h, --help            Gets help for version.
  -o, --output string   The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

Azure Dev CLI Install Instructions
Install scripts
MacOS/Linux

May elevate using sudo on some platforms and configurations

bash:
curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.sh | bash;
curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.sh | bash -s -- --base-url https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236 --version '' --verbose

pwsh:
Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.ps1' -OutFile uninstall-azd.ps1; ./uninstall-azd.ps1
Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.ps1' -OutFile install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236' -Version '' -Verbose

Windows
PowerShell install
powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.ps1' > uninstall-azd.ps1; ./uninstall-azd.ps1;"
powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.ps1' > install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236' -Version '' -Verbose;"

MSI install
powershell -c "irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.msi' -OutFile azd-windows-amd64.msi; msiexec /i azd-windows-amd64.msi /qn"

Standalone Binary

Linux - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-linux-amd64.tar.gz
MacOS - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-darwin-amd64.zip
Windows - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.zip

MSI

https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.msi

Container
docker run -it azdevcliextacr.azurecr.io/azure-dev:pr-1236

Documentation

learn.microsoft.com documentation

title: Azure Developer CLI Preview reference
description: This article explains the syntax and parameters for the various Azure Developer CLI Preview commands.
author: puichan
ms.author: puichan
ms.date: 01/13/23
ms.topic: conceptual
ms.custom: devx-track-azdevcli
ms.prod: azure
Azure Developer CLI Preview reference
This article explains the syntax and parameters for the various Azure Developer CLI Preview commands.
azd
Azure Developer CLI is a command-line interface for developers who build Azure solutions.
Synopsis
Azure Developer CLI is a command-line interface for developers who build Azure solutions.
To begin working with Azure Developer CLI, run the azd up command by supplying a sample template in an empty directory:
	azd up –-template todo-nodejs-mongo

You can pick a template by running azd template listand then supplying the repo name as a value to --template.
The most common next commands are:
	azd pipeline config
	azd deploy
	azd monitor --overview

For more information, visit the Azure Developer CLI Dev Hub: https://aka.ms/azure-dev/devhub.
Options
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
  -h, --help         Gets help for azd.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage Azure Developer CLI configuration
azd deploy: Deploy the application's code to Azure.
azd down: Delete Azure resources for an application.
azd env: Manage environments.
azd infra: Manage Azure resources.
azd init: Initialize a new application.
azd login: Log in to Azure.
azd logout: Log out of Azure
azd monitor: Monitor a deployed application.
azd pipeline: Manage GitHub Actions pipelines.
azd provision: Provision the Azure resources for an application.
azd restore: Restore application dependencies.
azd template: Manage templates.
azd up: Initialize application, provision Azure resources, and deploy your project with a single command.
azd version: Print the version number of Azure Developer CLI.

azd config
Manage Azure Developer CLI configuration
Synopsis
Manage the Azure Developer CLI user configuration, which includes your default Azure subscription and location.
The default value of the config directory is:

$HOME/.azd on Linux and MacOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
Options
  -h, --help   Gets help for config.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config get: Gets a configuration
azd config list: Lists all configuration values
azd config reset: Resets configuration to default
azd config set: Sets a configuration
azd config unset: Unsets a configuration
Back to top

azd config get
Gets a configuration
Synopsis
Gets a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and MacOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config get <path> [flags]

Options
  -h, --help            Gets help for get.
  -o, --output string   The output format (the supported formats are json). (default "json")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage Azure Developer CLI configuration
Back to top

azd config list
Lists all configuration values
Synopsis
Lists all configuration values in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and MacOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json). (default "json")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage Azure Developer CLI configuration
Back to top

azd config reset
Resets configuration to default
Synopsis
Resets all configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and MacOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable to the default.
azd config reset [flags]

Options
  -h, --help   Gets help for reset.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage Azure Developer CLI configuration
Back to top

azd config set
Sets a configuration
Synopsis
Sets a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and MacOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config set <path> <value> [flags]

Examples
azd config set defaults.subscription <yourSubscriptionID>
azd config set defaults.location eastus

Options
  -h, --help   Gets help for set.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage Azure Developer CLI configuration
Back to top

azd config unset
Unsets a configuration
Synopsis
Removes a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and MacOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config unset <path> [flags]

Examples
azd config unset defaults.location

Options
  -h, --help   Gets help for unset.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage Azure Developer CLI configuration
Back to top

azd deploy
Deploy the application's code to Azure.
Synopsis
Deploy the application's code to Azure.
When no --service value is specified, all services in the azure.yaml file (found in the root of your project) are deployed.
Examples:
	azd deploy
	azd deploy --service api
	azd deploy --service web

After the deployment is complete, the endpoint is printed. To start the service, select the endpoint or paste it in a browser.
azd deploy [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for deploy.
  -o, --output string        The output format (the supported formats are json, none). (default "none")
      --service string       Deploys a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are deployed).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd down
Delete Azure resources for an application.
azd down [flags]

Options
  -e, --environment string   The name of the environment to use.
      --force                Does not require confirmation before it deletes resources.
  -h, --help                 Gets help for down.
  -o, --output string        The output format (the supported formats are json, none). (default "none")
      --purge                Does not require confirmation before it permanently deletes resources that are soft-deleted by default (for example, key vaults).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd env
Manage environments.
Synopsis
Manage environments.
With this command group, you can create a new environment or get, set, and list your application environments. An application can have multiple environments (for example, dev, test, prod), each with a different configuration (that is, connectivity information) for accessing Azure resources.
You can find all environment configurations under the .azure<environment-name> folder. The environment name is stored as the AZURE_ENV_NAME environment variable in the .azure<environment-name>\folder.env file.
Options
  -h, --help   Gets help for env.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env get-values: Get all environment values.
azd env list: List environments
azd env new: Create a new environment.
azd env refresh: Refresh environment settings by using information from a previous infrastructure provision.
azd env select: Set the default environment.
azd env set: Set a value in the environment.
Back to top

azd env get-values
Get all environment values.
azd env get-values [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for get-values.
  -o, --output string        The output format (the supported formats are json, dotenv). (default "dotenv")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env list
List environments
azd env list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env new
Create a new environment.
azd env new <environment> [flags]

Options
  -h, --help                  Gets help for new.
  -l, --location string       Azure location for the new environment
      --subscription string   Name or ID of an Azure subscription to use for the new environment

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env refresh
Refresh environment settings by using information from a previous infrastructure provision.
azd env refresh [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for refresh.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env select
Set the default environment.
azd env select <environment> [flags]

Options
  -h, --help   Gets help for select.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env set
Set a value in the environment.
azd env set <key> <value> [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for set.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd infra
Manage Azure resources.
Options
  -h, --help   Gets help for infra.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra create: Create Azure resources for an application.
azd infra delete: Delete Azure resources for an application.
Back to top

azd infra create
Create Azure resources for an application.
azd infra create [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for create.
      --no-progress          Suppresses progress information.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra: Manage Azure resources.
Back to top

azd infra delete
Delete Azure resources for an application.
azd infra delete [flags]

Options
  -e, --environment string   The name of the environment to use.
      --force                Does not require confirmation before it deletes resources.
  -h, --help                 Gets help for delete.
      --purge                Does not require confirmation before it permanently deletes resources that are soft-deleted by default (for example, key vaults).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra: Manage Azure resources.
Back to top

azd init
Initialize a new application.
Synopsis
Initialize a new application.
When no template is supplied, you can optionally select an Azure Developer CLI template for cloning. Otherwise, azd init initializes the current directory and creates resources so that your project is compatible with Azure Developer CLI.
When a template is provided, the sample code is cloned to the current directory.
azd init [flags]

Options
  -b, --branch string         The template branch to initialize from.
  -e, --environment string    The name of the environment to use.
  -h, --help                  Gets help for init.
  -l, --location string       Azure location for the new environment
      --subscription string   Name or ID of an Azure subscription to use for the new environment
  -t, --template string       The template to use when you initialize the project. You can use Full URI, <owner>/<repository>, or <repository> if it's part of the azure-samples organization.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd login
Log in to Azure.
Synopsis
Log in to Azure.
When run without any arguments, log in interactively using a browser. To log in using a device code, pass
--use-device-code.
To log in as a service principal, pass --client-id and --tenant-id as well as one of: --client-secret,
--client-certificate, --federated-credential, or --federated-credential-provider.
azd login [flags]

Options
      --check-status                           Checks the log-in status instead of logging in.
      --client-certificate string              The path to the client certificate for the service principal to authenticate with.
      --client-id string                       The client id for the service principal to authenticate with.
      --client-secret string                   The client secret for the service principal to authenticate with. Set to the empty string to read the value from the console.
      --federated-credential string            The federated token for the service principal to authenticate with. Set to the empty string to read the value from the console.
      --federated-credential-provider string   The provider to use to acquire a federated token to authenticate with.
  -h, --help                                   Gets help for login.
  -o, --output string                          The output format (the supported formats are json, none). (default "none")
      --redirect-port int                      Choose the port to be used as part of the redirect URI during interactive login.
      --tenant-id string                       The tenant id for the service principal to authenticate with.
      --use-device-code                        When true, log in by using a device code instead of a browser.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd logout
Log out of Azure
Synopsis
Log out of Azure
azd logout [flags]

Options
  -h, --help   Gets help for logout.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd monitor
Monitor a deployed application.
Synopsis
Monitor a deployed application.
Examples:
	azd monitor --overview
	azd monitor -–live
	azd monitor --logs

For more information, go to https://aka.ms/azure-dev/monitor.
azd monitor [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for monitor.
      --live                 Open a browser to Application Insights Live Metrics. Live Metrics is currently not supported for Python applications.
      --logs                 Open a browser to Application Insights Logs.
      --overview             Open a browser to Application Insights Overview Dashboard.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd pipeline
Manage GitHub Actions pipelines.
Synopsis
Manage GitHub Actions pipelines.
The Azure Developer CLI template includes a GitHub Actions pipeline configuration file (in the .github/workflows folder) that deploys your application whenever code is pushed to the main branch.
For more information, go to https://aka.ms/azure-dev/pipeline.
Options
  -h, --help   Gets help for pipeline.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd pipeline config: Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
Back to top

azd pipeline config
Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
Synopsis
Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
For more information, go to https://aka.ms/azure-dev/pipeline.
azd pipeline config [flags]

Options
      --auth-type string        The authentication type used between the pipeline provider and Azure for deployment (Only valid for GitHub provider)
  -e, --environment string      The name of the environment to use.
  -h, --help                    Gets help for config.
      --principal-name string   The name of the service principal to use to grant access to Azure resources as part of the pipeline.
      --principal-role string   The role to assign to the service principal. (default "contributor")
      --provider string         The pipeline provider to use (github for Github Actions and azdo for Azure Pipelines). (default "github")
      --remote-name string      The name of the git remote to configure the pipeline to run on. (default "origin")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd pipeline: Manage GitHub Actions pipelines.
Back to top

azd provision
Provision the Azure resources for an application.
Synopsis
Provision the Azure resources for an application.
The command prompts you for the following:

Environment name: The name of your environment.
Azure location: The Azure location where your resources will be deployed.
Azure subscription: The Azure subscription where your resources will be deployed.

Depending on what Azure resources are created, running this command might take a while. To view progress, go to the Azure portal and search for the resource group that contains your environment name.
azd provision [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for provision.
      --no-progress          Suppresses progress information.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd restore
Restore application dependencies.
Synopsis
Restore application dependencies.
Run this command to download and install all the required libraries so that you can build, run, and debug the application locally.
For the best local run and debug experience, go to https://aka.ms/azure-dev/vscode to learn how to use the Visual Studio Code extension.
azd restore [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for restore.
      --service string       Restores a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are restored).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd template
Manage templates.
Options
  -h, --help   Gets help for template.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template list: List templates.
azd template show: Show the template details.
Back to top

azd template list
List templates.
azd template list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template: Manage templates.
Back to top

azd template show
Show the template details.
azd template show <template> [flags]

Options
  -h, --help            Gets help for show.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template: Manage templates.
Back to top

azd up
Initialize application, provision Azure resources, and deploy your project with a single command.
Synopsis
Initialize the project (if the project folder has not been initialized or cloned from a template), provision Azure resources, and deploy your project with a single command.
This command executes the following in one step:
	azd init
	azd provision
	azd deploy

When no template is supplied, you can optionally select an Azure Developer CLI template for cloning. Otherwise, running azd up initializes the current directory so that your project is compatible with Azure Developer CLI.
azd up [flags]

Options
  -b, --branch string         The template branch to initialize from.
  -e, --environment string    The name of the environment to use.
  -h, --help                  Gets help for up.
  -l, --location string       Azure location for the new environment
      --no-progress           Suppresses progress information.
  -o, --output string         The output format (the supported formats are json, none). (default "none")
      --service string        Deploys a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are deployed).
      --subscription string   Name or ID of an Azure subscription to use for the new environment
  -t, --template string       The template to use when you initialize the project. You can use Full URI, <owner>/<repository>, or <repository> if it's part of the azure-samples organization.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd version
Print the version number of Azure Developer CLI.
azd version [flags]

Options
  -h, --help            Gets help for version.
  -o, --output string   The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

Azure Dev CLI Install Instructions
Install scripts
MacOS/Linux

May elevate using sudo on some platforms and configurations

bash:
curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.sh | bash;
curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.sh | bash -s -- --base-url https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236 --version '' --verbose

pwsh:
Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.ps1' -OutFile uninstall-azd.ps1; ./uninstall-azd.ps1
Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.ps1' -OutFile install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236' -Version '' -Verbose

Windows
PowerShell install
powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.ps1' > uninstall-azd.ps1; ./uninstall-azd.ps1;"
powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.ps1' > install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236' -Version '' -Verbose;"

MSI install
powershell -c "irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.msi' -OutFile azd-windows-amd64.msi; msiexec /i azd-windows-amd64.msi /qn"

Standalone Binary

Linux - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-linux-amd64.tar.gz
MacOS - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-darwin-amd64.zip
Windows - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.zip

MSI

https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.msi

Container
docker run -it azdevcliextacr.azurecr.io/azure-dev:pr-1236

Documentation

learn.microsoft.com documentation

title: Azure Developer CLI reference (preview)
description: This article explains the syntax and parameters for the various Azure Developer CLI Preview commands.
author: hhunter-ms
ms.author: hannahhunter
ms.date: 01/18/2023
ms.service: azure-dev-cli
ms.topic: conceptual
ms.custom: devx-track-azdevcli
Azure Developer CLI reference (preview)
This article explains the syntax and parameters for the various Azure Developer CLI Preview commands.
azd
Azure Developer CLI (azd) is a command-line interface for developers who build Azure solutions.
Synopsis
To begin working with Azure Developer CLI, run the azd up command by supplying a sample template in an empty directory:
	azd up –-template todo-nodejs-mongo

You can pick a template by running azd template list and then supplying the repo name as a value to --template.
The most common next commands are:
	azd pipeline config
	azd deploy
	azd monitor --overview

For more information, visit the Azure Developer CLI Dev Hub: https://aka.ms/azure-dev/devhub.
Options
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
  -h, --help         Gets help for azd.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
azd deploy: Deploy the app's code to Azure.
azd down: Delete Azure resources for an app.
azd env: Manage environments.
azd infra: Manage Azure resources.
azd init: Initialize a new app.
azd login: Log in to Azure.
azd logout: Log out of Azure
azd monitor: Monitor a deployed app.
azd pipeline: Manage GitHub Actions or Azure Pipelines.
azd provision: Provision the Azure resources for an app.
azd restore: Restore app dependencies.
azd template: Manage templates.
azd up: Initialize the app, provision Azure resources, and deploy your project with a single command.
azd version: Print the version number of Azure Developer CLI.

azd config
Manage the Azure Developer CLI user configuration.
Synopsis
Manage the Azure Developer CLI user configuration, which includes your default Azure subscription and location.
Available since azure-dev-cli_0.4.0-beta.1.
The easiest way to configure azd for the first time is to run azd init. The subscription and location you select will be stored in the config.json file located in the config directory. To configure azd anytime afterwards, you'll use azd config set.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
Options
  -h, --help   Gets help for config.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config get: Gets a configuration
azd config list: Lists all configuration values
azd config reset: Resets configuration to default
azd config set: Sets a configuration
azd config unset: Unsets a configuration
Back to top

azd config get
Gets a configuration
Synopsis
Gets a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config get <path> [flags]

Options
  -h, --help            Gets help for get.
  -o, --output string   The output format (the supported formats are json). (default "json")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd config list
Lists all configuration values
Synopsis
Lists all configuration values in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json). (default "json")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd config reset
Resets configuration to default
Synopsis
Resets all configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable to the default.
azd config reset [flags]

Options
  -h, --help   Gets help for reset.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd config set
Sets a configuration
Synopsis
Sets a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config set <path> <value> [flags]

Examples
azd config set defaults.subscription <yourSubscriptionID>
azd config set defaults.location eastus

Options
  -h, --help   Gets help for set.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd config unset
Unsets a configuration
Synopsis
Removes a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config unset <path> [flags]

Examples
azd config unset defaults.location

Options
  -h, --help   Gets help for unset.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd deploy
Deploy the app's code to Azure.
Synopsis
Deploy the app's code to Azure.
When no --service value is specified, all services in the azure.yaml file (found in the root of your project) are deployed.
Examples:
	azd deploy
	azd deploy --service api
	azd deploy --service web

After the deployment is complete, the endpoint is printed. To start the service, select the endpoint or paste it in a browser.
azd deploy [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for deploy.
  -o, --output string        The output format (the supported formats are json, none). (default "none")
      --service string       Deploys a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are deployed).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd down
Delete Azure resources for an app.
azd down [flags]

Options
  -e, --environment string   The name of the environment to use.
      --force                Does not require confirmation before it deletes resources.
  -h, --help                 Gets help for down.
  -o, --output string        The output format (the supported formats are json, none). (default "none")
      --purge                Does not require confirmation before it permanently deletes resources that are soft-deleted by default (for example, key vaults).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd env
Manage environments.
Synopsis
Manage environments.
With this command group, you can create a new environment or get, set, and list your app environments. An app can have multiple environments (for example, dev, test, prod), each with a different configuration (that is, connectivity information) for accessing Azure resources.
You can find all environment configurations under the .azure\<environment-name> directories. The environment name is stored as the AZURE_ENV_NAME environment variable in the .azure\<environment-name>\directory\.env file.
Options
  -h, --help   Gets help for env.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env get-values: Get all environment values.
azd env list: List environments.
azd env new: Create a new environment.
azd env refresh: Refresh environment settings by using information from a previous infrastructure provision.
azd env select: Set the default environment.
azd env set: Set a value in the environment.
Back to top

azd env get-values
Get all environment values.
azd env get-values [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for get-values.
  -o, --output string        The output format (the supported formats are json, dotenv). (default "dotenv")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env list
List environments.
azd env list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env new
Create a new environment.
azd env new <environment> [flags]

Options
  -h, --help                  Gets help for new.
  -l, --location string       Azure location for the new environment
      --subscription string   Name or ID of an Azure subscription to use for the new environment

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env refresh
Refresh environment settings by using information from a previous infrastructure provision.
azd env refresh [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for refresh.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env select
Set the default environment.
azd env select <environment> [flags]

Options
  -h, --help   Gets help for select.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env set
Set a value in the environment.
azd env set <key> <value> [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for set.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd infra
Manage Azure resources.
Options
  -h, --help   Gets help for infra.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra create: Create Azure resources for an app.
azd infra delete: Delete Azure resources for an app.
Back to top

azd infra create
Create Azure resources for an app.
azd infra create [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for create.
      --no-progress          Suppresses progress information.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra: Manage Azure resources.
Back to top

azd infra delete
Delete Azure resources for an app.
azd infra delete [flags]

Options
  -e, --environment string   The name of the environment to use.
      --force                Does not require confirmation before it deletes resources.
  -h, --help                 Gets help for delete.
      --purge                Does not require confirmation before it permanently deletes resources that are soft-deleted by default (for example, key vaults).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra: Manage Azure resources.
Back to top

azd init
Initialize a new app.
Synopsis
Initialize a new app.
When no template is supplied, you can optionally select an Azure Developer CLI template for cloning. Otherwise, azd init initializes the current directory and creates resources so that your project is compatible with Azure Developer CLI.
When a template is provided, the sample code is cloned to the current directory.
azd init [flags]

Options
  -b, --branch string         The template branch to initialize from.
  -e, --environment string    The name of the environment to use.
  -h, --help                  Gets help for init.
  -l, --location string       Azure location for the new environment
      --subscription string   Name or ID of an Azure subscription to use for the new environment
  -t, --template string       The template to use when you initialize the project. You can use Full URI, <owner>/<repository>, or <repository> if it's part of the azure-samples organization.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd login
Log in to Azure.
Synopsis
Log in to Azure.
When run without any arguments, log in interactively using a browser. To log in using a device code, pass
--use-device-code.
To log in as a service principal, pass --client-id and --tenant-id as well as one of: --client-secret,
--client-certificate, --federated-credential, or --federated-credential-provider.
azd login [flags]

Options
      --check-status                           Checks the log-in status instead of logging in.
      --client-certificate string              The path to the client certificate for the service principal to authenticate with.
      --client-id string                       The client id for the service principal to authenticate with.
      --client-secret string                   The client secret for the service principal to authenticate with. Set to the empty string to read the value from the console.
      --federated-credential string            The federated token for the service principal to authenticate with. Set to the empty string to read the value from the console.
      --federated-credential-provider string   The provider to use to acquire a federated token to authenticate with.
  -h, --help                                   Gets help for login.
  -o, --output string                          The output format (the supported formats are json, none). (default "none")
      --redirect-port int                      Choose the port to be used as part of the redirect URI during interactive login.
      --tenant-id string                       The tenant id for the service principal to authenticate with.
      --use-device-code                        When true, log in by using a device code instead of a browser.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd logout
Log out of Azure
Synopsis
Log out of Azure
azd logout [flags]

Options
  -h, --help   Gets help for logout.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd monitor
Monitor a deployed app.
Synopsis
Monitor a deployed app.
Examples:
	azd monitor --overview
	azd monitor -–live
	azd monitor --logs

For more information, go to https://aka.ms/azure-dev/monitor.
azd monitor [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for monitor.
      --live                 Open a browser to Application Insights Live Metrics. Live Metrics is currently not supported for Python apps.
      --logs                 Open a browser to Application Insights Logs.
      --overview             Open a browser to Application Insights Overview Dashboard.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd pipeline
Manage GitHub Actions or Azure Pipelines.
Synopsis
Manage GitHub Actions or Azure Pipelines.
The Azure Developer CLI template includes a GitHub Actions and an Azure Pipeline configuration file in the .github/workflows and .azdo/pipelines directories respectively. The configuration file deploys your app whenever code is pushed to the main branch.
For more information, go to https://aka.ms/azure-dev/pipeline.
Options
  -h, --help   Gets help for pipeline.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd pipeline config: Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
Back to top

azd pipeline config
Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
Synopsis
Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
For more information, go to https://aka.ms/azure-dev/pipeline.
azd pipeline config [flags]

Options
      --auth-type string        The authentication type used between the pipeline provider and Azure for deployment (Only valid for GitHub provider)
  -e, --environment string      The name of the environment to use.
  -h, --help                    Gets help for config.
      --principal-name string   The name of the service principal to use to grant access to Azure resources as part of the pipeline.
      --principal-role string   The role to assign to the service principal. (default "contributor")
      --provider string         The pipeline provider to use (github for Github Actions and azdo for Azure Pipelines). (default "github")
      --remote-name string      The name of the git remote to configure the pipeline to run on. (default "origin")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd pipeline: Manage GitHub Actions or Azure Pipelines.
Back to top

azd provision
Provision the Azure resources for an app.
Synopsis
Provision the Azure resources for an app.
The command prompts you for the following values:

Environment name: The name of your environment.
Azure location: The Azure location where your resources will be deployed.
Azure subscription: The Azure subscription where your resources will be deployed.

Depending on what Azure resources are created, running this command might take a while. To view progress, go to the Azure portal and search for the resource group that contains your environment name.
azd provision [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for provision.
      --no-progress          Suppresses progress information.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd restore
Restore app dependencies.
Synopsis
Restore app dependencies.
Run this command to download and install all the required libraries so that you can build, run, and debug the app locally.
For the best local run and debug experience, go to https://aka.ms/azure-dev/vscode to learn how to use the Visual Studio Code extension.
azd restore [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for restore.
      --service string       Restores a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are restored).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd template
Manage templates.
Options
  -h, --help   Gets help for template.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template list: List templates.
azd template show: Show the template details.
Back to top

azd template list
List templates.
azd template list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template: Manage templates.
Back to top

azd template show
Show the template details.
azd template show <template> [flags]

Options
  -h, --help            Gets help for show.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template: Manage templates.
Back to top

azd up
Initialize the app, provision Azure resources, and deploy your project with a single command.
Synopsis
Initialize the project (if the project folder has not been initialized or cloned from a template), provision Azure resources, and deploy your project with a single command.
This command executes the following in one step:
	azd init
	azd provision
	azd deploy

When no template is supplied, you can optionally select an Azure Developer CLI template for cloning. Otherwise, running azd up initializes the current directory so that your project is compatible with Azure Developer CLI.
azd up [flags]

Options
  -b, --branch string         The template branch to initialize from.
  -e, --environment string    The name of the environment to use.
  -h, --help                  Gets help for up.
  -l, --location string       Azure location for the new environment
      --no-progress           Suppresses progress information.
  -o, --output string         The output format (the supported formats are json, none). (default "none")
      --service string        Deploys a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are deployed).
      --subscription string   Name or ID of an Azure subscription to use for the new environment
  -t, --template string       The template to use when you initialize the project. You can use Full URI, <owner>/<repository>, or <repository> if it's part of the azure-samples organization.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd version
Print the version number of Azure Developer CLI.
azd version [flags]

Options
  -h, --help            Gets help for version.
  -o, --output string   The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

Azure Dev CLI Install Instructions
Install scripts
MacOS/Linux

May elevate using sudo on some platforms and configurations

bash:
curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.sh | bash;
curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.sh | bash -s -- --base-url https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236 --version '' --verbose

pwsh:
Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.ps1' -OutFile uninstall-azd.ps1; ./uninstall-azd.ps1
Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.ps1' -OutFile install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236' -Version '' -Verbose

Windows
PowerShell install
powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.ps1' > uninstall-azd.ps1; ./uninstall-azd.ps1;"
powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.ps1' > install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236' -Version '' -Verbose;"

MSI install
powershell -c "irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.msi' -OutFile azd-windows-amd64.msi; msiexec /i azd-windows-amd64.msi /qn"

Standalone Binary

Linux - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-linux-amd64.tar.gz
MacOS - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-darwin-amd64.zip
Windows - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.zip

MSI

https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.msi

Container
docker run -it azdevcliextacr.azurecr.io/azure-dev:pr-1236

Documentation

learn.microsoft.com documentation

title: Azure Developer CLI reference (preview)
description: This article explains the syntax and parameters for the various Azure Developer CLI Preview commands.
author: hhunter-ms
ms.author: hannahhunter
ms.date: 01/18/2023
ms.service: azure-dev-cli
ms.topic: conceptual
ms.custom: devx-track-azdevcli
Azure Developer CLI reference (preview)
This article explains the syntax and parameters for the various Azure Developer CLI Preview commands.
azd
Azure Developer CLI (azd) is a command-line interface for developers who build Azure solutions.
Synopsis
To begin working with Azure Developer CLI, run the azd up command by supplying a sample template in an empty directory:
	azd up –-template todo-nodejs-mongo

You can pick a template by running azd template list and then supplying the repo name as a value to --template.
The most common next commands are:
	azd pipeline config
	azd deploy
	azd monitor --overview

For more information, visit the Azure Developer CLI Dev Hub: https://aka.ms/azure-dev/devhub.
Options
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
  -h, --help         Gets help for azd.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
azd deploy: Deploy the app's code to Azure.
azd down: Delete Azure resources for an app.
azd env: Manage environments.
azd infra: Manage Azure resources.
azd init: Initialize a new app.
azd login: Log in to Azure.
azd logout: Log out of Azure
azd monitor: Monitor a deployed app.
azd pipeline: Manage GitHub Actions or Azure Pipelines.
azd provision: Provision the Azure resources for an app.
azd restore: Restore app dependencies.
azd template: Manage templates.
azd up: Initialize the app, provision Azure resources, and deploy your project with a single command.
azd version: Print the version number of Azure Developer CLI.

azd config
Manage the Azure Developer CLI user configuration.
Synopsis
Manage the Azure Developer CLI user configuration, which includes your default Azure subscription and location.
Available since azure-dev-cli_0.4.0-beta.1.
The easiest way to configure azd for the first time is to run azd init. The subscription and location you select will be stored in the config.json file located in the config directory. To configure azd anytime afterwards, you'll use azd config set.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
Options
  -h, --help   Gets help for config.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config get: Gets a configuration
azd config list: Lists all configuration values
azd config reset: Resets configuration to default
azd config set: Sets a configuration
azd config unset: Unsets a configuration
Back to top

azd config get
Gets a configuration
Synopsis
Gets a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config get <path> [flags]

Options
  -h, --help            Gets help for get.
  -o, --output string   The output format (the supported formats are json). (default "json")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd config list
Lists all configuration values
Synopsis
Lists all configuration values in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json). (default "json")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd config reset
Resets configuration to default
Synopsis
Resets all configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable to the default.
azd config reset [flags]

Options
  -h, --help   Gets help for reset.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd config set
Sets a configuration
Synopsis
Sets a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config set <path> <value> [flags]

Examples
azd config set defaults.subscription <yourSubscriptionID>
azd config set defaults.location eastus

Options
  -h, --help   Gets help for set.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd config unset
Unsets a configuration
Synopsis
Removes a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config unset <path> [flags]

Examples
azd config unset defaults.location

Options
  -h, --help   Gets help for unset.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd deploy
Deploy the app's code to Azure.
Synopsis
Deploy the app's code to Azure.
When no --service value is specified, all services in the azure.yaml file (found in the root of your project) are deployed.
Examples:
	azd deploy
	azd deploy --service api
	azd deploy --service web

After the deployment is complete, the endpoint is printed. To start the service, select the endpoint or paste it in a browser.
azd deploy [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for deploy.
  -o, --output string        The output format (the supported formats are json, none). (default "none")
      --service string       Deploys a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are deployed).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd down
Delete Azure resources for an app.
azd down [flags]

Options
  -e, --environment string   The name of the environment to use.
      --force                Does not require confirmation before it deletes resources.
  -h, --help                 Gets help for down.
  -o, --output string        The output format (the supported formats are json, none). (default "none")
      --purge                Does not require confirmation before it permanently deletes resources that are soft-deleted by default (for example, key vaults).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd env
Manage environments.
Synopsis
Manage environments.
With this command group, you can create a new environment or get, set, and list your app environments. An app can have multiple environments (for example, dev, test, prod), each with a different configuration (that is, connectivity information) for accessing Azure resources.
You can find all environment configurations under the .azure\<environment-name> directories. The environment name is stored as the AZURE_ENV_NAME environment variable in the .azure\<environment-name>\directory\.env file.
Options
  -h, --help   Gets help for env.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env get-values: Get all environment values.
azd env list: List environments.
azd env new: Create a new environment.
azd env refresh: Refresh environment settings by using information from a previous infrastructure provision.
azd env select: Set the default environment.
azd env set: Set a value in the environment.
Back to top

azd env get-values
Get all environment values.
azd env get-values [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for get-values.
  -o, --output string        The output format (the supported formats are json, dotenv). (default "dotenv")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env list
List environments.
azd env list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env new
Create a new environment.
azd env new <environment> [flags]

Options
  -h, --help                  Gets help for new.
  -l, --location string       Azure location for the new environment
      --subscription string   Name or ID of an Azure subscription to use for the new environment

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env refresh
Refresh environment settings by using information from a previous infrastructure provision.
azd env refresh [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for refresh.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env select
Set the default environment.
azd env select <environment> [flags]

Options
  -h, --help   Gets help for select.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env set
Set a value in the environment.
azd env set <key> <value> [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for set.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd infra
Manage Azure resources.
Options
  -h, --help   Gets help for infra.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra create: Create Azure resources for an app.
azd infra delete: Delete Azure resources for an app.
Back to top

azd infra create
Create Azure resources for an app.
azd infra create [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for create.
      --no-progress          Suppresses progress information.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra: Manage Azure resources.
Back to top

azd infra delete
Delete Azure resources for an app.
azd infra delete [flags]

Options
  -e, --environment string   The name of the environment to use.
      --force                Does not require confirmation before it deletes resources.
  -h, --help                 Gets help for delete.
      --purge                Does not require confirmation before it permanently deletes resources that are soft-deleted by default (for example, key vaults).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra: Manage Azure resources.
Back to top

azd init
Initialize a new app.
Synopsis
Initialize a new app.
When no template is supplied, you can optionally select an Azure Developer CLI template for cloning. Otherwise, azd init initializes the current directory and creates resources so that your project is compatible with Azure Developer CLI.
When a template is provided, the sample code is cloned to the current directory.
azd init [flags]

Options
  -b, --branch string         The template branch to initialize from.
  -e, --environment string    The name of the environment to use.
  -h, --help                  Gets help for init.
  -l, --location string       Azure location for the new environment
      --subscription string   Name or ID of an Azure subscription to use for the new environment
  -t, --template string       The template to use when you initialize the project. You can use Full URI, <owner>/<repository>, or <repository> if it's part of the azure-samples organization.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd login
Log in to Azure.
Synopsis
Log in to Azure.
When run without any arguments, log in interactively using a browser. To log in using a device code, pass
--use-device-code.
To log in as a service principal, pass --client-id and --tenant-id as well as one of: --client-secret,
--client-certificate, --federated-credential, or --federated-credential-provider.
azd login [flags]

Options
      --check-status                           Checks the log-in status instead of logging in.
      --client-certificate string              The path to the client certificate for the service principal to authenticate with.
      --client-id string                       The client id for the service principal to authenticate with.
      --client-secret string                   The client secret for the service principal to authenticate with. Set to the empty string to read the value from the console.
      --federated-credential string            The federated token for the service principal to authenticate with. Set to the empty string to read the value from the console.
      --federated-credential-provider string   The provider to use to acquire a federated token to authenticate with.
  -h, --help                                   Gets help for login.
  -o, --output string                          The output format (the supported formats are json, none). (default "none")
      --redirect-port int                      Choose the port to be used as part of the redirect URI during interactive login.
      --tenant-id string                       The tenant id for the service principal to authenticate with.
      --use-device-code                        When true, log in by using a device code instead of a browser.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd logout
Log out of Azure
Synopsis
Log out of Azure
azd logout [flags]

Options
  -h, --help   Gets help for logout.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd monitor
Monitor a deployed app.
Synopsis
Monitor a deployed app.
Examples:
	azd monitor --overview
	azd monitor -–live
	azd monitor --logs

For more information, go to https://aka.ms/azure-dev/monitor.
azd monitor [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for monitor.
      --live                 Open a browser to Application Insights Live Metrics. Live Metrics is currently not supported for Python apps.
      --logs                 Open a browser to Application Insights Logs.
      --overview             Open a browser to Application Insights Overview Dashboard.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd pipeline
Manage GitHub Actions or Azure Pipelines.
Synopsis
Manage GitHub Actions or Azure Pipelines.
The Azure Developer CLI template includes a GitHub Actions and an Azure Pipeline configuration file in the .github/workflows and .azdo/pipelines directories respectively. The configuration file deploys your app whenever code is pushed to the main branch.
For more information, go to https://aka.ms/azure-dev/pipeline.
Options
  -h, --help   Gets help for pipeline.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd pipeline config: Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
Back to top

azd pipeline config
Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
Synopsis
Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
For more information, go to https://aka.ms/azure-dev/pipeline.
azd pipeline config [flags]

Options
      --auth-type string        The authentication type used between the pipeline provider and Azure for deployment (Only valid for GitHub provider)
  -e, --environment string      The name of the environment to use.
  -h, --help                    Gets help for config.
      --principal-name string   The name of the service principal to use to grant access to Azure resources as part of the pipeline.
      --principal-role string   The role to assign to the service principal. (default "contributor")
      --provider string         The pipeline provider to use (github for Github Actions and azdo for Azure Pipelines). (default "github")
      --remote-name string      The name of the git remote to configure the pipeline to run on. (default "origin")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd pipeline: Manage GitHub Actions or Azure Pipelines.
Back to top

azd provision
Provision the Azure resources for an app.
Synopsis
Provision the Azure resources for an app.
The command prompts you for the following values:

Environment name: The name of your environment.
Azure location: The Azure location where your resources will be deployed.
Azure subscription: The Azure subscription where your resources will be deployed.

Depending on what Azure resources are created, running this command might take a while. To view progress, go to the Azure portal and search for the resource group that contains your environment name.
azd provision [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for provision.
      --no-progress          Suppresses progress information.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd restore
Restore app dependencies.
Synopsis
Restore app dependencies.
Run this command to download and install all the required libraries so that you can build, run, and debug the app locally.
For the best local run and debug experience, go to https://aka.ms/azure-dev/vscode to learn how to use the Visual Studio Code extension.
azd restore [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for restore.
      --service string       Restores a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are restored).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd template
Manage templates.
Options
  -h, --help   Gets help for template.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template list: List templates.
azd template show: Show the template details.
Back to top

azd template list
List templates.
azd template list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template: Manage templates.
Back to top

azd template show
Show the template details.
azd template show <template> [flags]

Options
  -h, --help            Gets help for show.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template: Manage templates.
Back to top

azd up
Initialize the app, provision Azure resources, and deploy your project with a single command.
Synopsis
Initialize the project (if the project folder has not been initialized or cloned from a template), provision Azure resources, and deploy your project with a single command.
This command executes the following in one step:
	azd init
	azd provision
	azd deploy

When no template is supplied, you can optionally select an Azure Developer CLI template for cloning. Otherwise, running azd up initializes the current directory so that your project is compatible with Azure Developer CLI.
azd up [flags]

Options
  -b, --branch string         The template branch to initialize from.
  -e, --environment string    The name of the environment to use.
  -h, --help                  Gets help for up.
  -l, --location string       Azure location for the new environment
      --no-progress           Suppresses progress information.
  -o, --output string         The output format (the supported formats are json, none). (default "none")
      --service string        Deploys a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are deployed).
      --subscription string   Name or ID of an Azure subscription to use for the new environment
  -t, --template string       The template to use when you initialize the project. You can use Full URI, <owner>/<repository>, or <repository> if it's part of the azure-samples organization.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd version
Print the version number of Azure Developer CLI.
azd version [flags]

Options
  -h, --help            Gets help for version.
  -o, --output string   The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

I want to push back a little on the implicit hooks stuff. I'm not 100% sure what the use case is here (given that we encourage folks /not/ to check in the .azure folder) and I think it's existence is going to raise a lot of questions we don't want to have raised right now.
Are there cases where this is helpful vs the inline scripts and things defined explicitly in azure.yaml?
If we do want to keep this - I think we need to take a step back and think about how we want to structure the .azure folder. As is, right now we have assumptions baked into the system that the directories under the .azure folder are environments (see AzdContext::ListEnvironments for example) and we would need to adopt that. I think as we might have an issue if you ever tried to create an environment called "hooks" and also this hooks thing will show up in azd env list

I'm happy to simplify for the the time being and get some feedback from the community before rolling the implicit hooks feature out.

Azure Dev CLI Install Instructions
Install scripts
MacOS/Linux

May elevate using sudo on some platforms and configurations

bash:
curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.sh | bash;
curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.sh | bash -s -- --base-url https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236 --version '' --verbose

pwsh:
Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.ps1' -OutFile uninstall-azd.ps1; ./uninstall-azd.ps1
Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.ps1' -OutFile install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236' -Version '' -Verbose

Windows
PowerShell install
powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/uninstall-azd.ps1' > uninstall-azd.ps1; ./uninstall-azd.ps1;"
powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/install-azd.ps1' > install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236' -Version '' -Verbose;"

MSI install
powershell -c "irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.msi' -OutFile azd-windows-amd64.msi; msiexec /i azd-windows-amd64.msi /qn"

Standalone Binary

Linux - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-linux-amd64.tar.gz
MacOS - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-darwin-amd64.zip
Windows - https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.zip

MSI

https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/1236/azd-windows-amd64.msi

Container
docker run -it azdevcliextacr.azurecr.io/azure-dev:pr-1236

Documentation

learn.microsoft.com documentation

title: Azure Developer CLI reference (preview)
description: This article explains the syntax and parameters for the various Azure Developer CLI Preview commands.
author: hhunter-ms
ms.author: hannahhunter
ms.date: 01/18/2023
ms.service: azure-dev-cli
ms.topic: conceptual
ms.custom: devx-track-azdevcli
Azure Developer CLI reference (preview)
This article explains the syntax and parameters for the various Azure Developer CLI Preview commands.
azd
Azure Developer CLI (azd) is a command-line interface for developers who build Azure solutions.
Synopsis
To begin working with Azure Developer CLI, run the azd up command by supplying a sample template in an empty directory:
	azd up –-template todo-nodejs-mongo

You can pick a template by running azd template list and then supplying the repo name as a value to --template.
The most common next commands are:
	azd pipeline config
	azd deploy
	azd monitor --overview

For more information, visit the Azure Developer CLI Dev Hub: https://aka.ms/azure-dev/devhub.
Options
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
  -h, --help         Gets help for azd.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
azd deploy: Deploy the app's code to Azure.
azd down: Delete Azure resources for an app.
azd env: Manage environments.
azd infra: Manage Azure resources.
azd init: Initialize a new app.
azd login: Log in to Azure.
azd logout: Log out of Azure
azd monitor: Monitor a deployed app.
azd pipeline: Manage GitHub Actions or Azure Pipelines.
azd provision: Provision the Azure resources for an app.
azd restore: Restore app dependencies.
azd template: Manage templates.
azd up: Initialize the app, provision Azure resources, and deploy your project with a single command.
azd version: Print the version number of Azure Developer CLI.

azd config
Manage the Azure Developer CLI user configuration.
Synopsis
Manage the Azure Developer CLI user configuration, which includes your default Azure subscription and location.
Available since azure-dev-cli_0.4.0-beta.1.
The easiest way to configure azd for the first time is to run azd init. The subscription and location you select will be stored in the config.json file located in the config directory. To configure azd anytime afterwards, you'll use azd config set.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
Options
  -h, --help   Gets help for config.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config get: Gets a configuration
azd config list: Lists all configuration values
azd config reset: Resets configuration to default
azd config set: Sets a configuration
azd config unset: Unsets a configuration
Back to top

azd config get
Gets a configuration
Synopsis
Gets a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config get <path> [flags]

Options
  -h, --help            Gets help for get.
  -o, --output string   The output format (the supported formats are json). (default "json")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd config list
Lists all configuration values
Synopsis
Lists all configuration values in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json). (default "json")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd config reset
Resets configuration to default
Synopsis
Resets all configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable to the default.
azd config reset [flags]

Options
  -h, --help   Gets help for reset.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd config set
Sets a configuration
Synopsis
Sets a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config set <path> <value> [flags]

Examples
azd config set defaults.subscription <yourSubscriptionID>
azd config set defaults.location eastus

Options
  -h, --help   Gets help for set.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd config unset
Unsets a configuration
Synopsis
Removes a configuration in the configuration path.
The default value of the config directory is:

$HOME/.azd on Linux and macOS
%USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.
azd config unset <path> [flags]

Examples
azd config unset defaults.location

Options
  -h, --help   Gets help for unset.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config: Manage the Azure Developer CLI user configuration.
Back to top

azd deploy
Deploy the app's code to Azure.
Synopsis
Deploy the app's code to Azure.
When no --service value is specified, all services in the azure.yaml file (found in the root of your project) are deployed.
Examples:
	azd deploy
	azd deploy --service api
	azd deploy --service web

After the deployment is complete, the endpoint is printed. To start the service, select the endpoint or paste it in a browser.
azd deploy [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for deploy.
  -o, --output string        The output format (the supported formats are json, none). (default "none")
      --service string       Deploys a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are deployed).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd down
Delete Azure resources for an app.
azd down [flags]

Options
  -e, --environment string   The name of the environment to use.
      --force                Does not require confirmation before it deletes resources.
  -h, --help                 Gets help for down.
  -o, --output string        The output format (the supported formats are json, none). (default "none")
      --purge                Does not require confirmation before it permanently deletes resources that are soft-deleted by default (for example, key vaults).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd env
Manage environments.
Synopsis
Manage environments.
With this command group, you can create a new environment or get, set, and list your app environments. An app can have multiple environments (for example, dev, test, prod), each with a different configuration (that is, connectivity information) for accessing Azure resources.
You can find all environment configurations under the .azure\<environment-name> directories. The environment name is stored as the AZURE_ENV_NAME environment variable in the .azure\<environment-name>\directory\.env file.
Options
  -h, --help   Gets help for env.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env get-values: Get all environment values.
azd env list: List environments.
azd env new: Create a new environment.
azd env refresh: Refresh environment settings by using information from a previous infrastructure provision.
azd env select: Set the default environment.
azd env set: Set a value in the environment.
Back to top

azd env get-values
Get all environment values.
azd env get-values [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for get-values.
  -o, --output string        The output format (the supported formats are json, dotenv). (default "dotenv")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env list
List environments.
azd env list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env new
Create a new environment.
azd env new <environment> [flags]

Options
  -h, --help                  Gets help for new.
  -l, --location string       Azure location for the new environment
      --subscription string   Name or ID of an Azure subscription to use for the new environment

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env refresh
Refresh environment settings by using information from a previous infrastructure provision.
azd env refresh [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for refresh.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env select
Set the default environment.
azd env select <environment> [flags]

Options
  -h, --help   Gets help for select.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd env set
Set a value in the environment.
azd env set <key> <value> [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for set.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env: Manage environments.
Back to top

azd infra
Manage Azure resources.
Options
  -h, --help   Gets help for infra.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra create: Create Azure resources for an app.
azd infra delete: Delete Azure resources for an app.
Back to top

azd infra create
Create Azure resources for an app.
azd infra create [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for create.
      --no-progress          Suppresses progress information.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra: Manage Azure resources.
Back to top

azd infra delete
Delete Azure resources for an app.
azd infra delete [flags]

Options
  -e, --environment string   The name of the environment to use.
      --force                Does not require confirmation before it deletes resources.
  -h, --help                 Gets help for delete.
      --purge                Does not require confirmation before it permanently deletes resources that are soft-deleted by default (for example, key vaults).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd infra: Manage Azure resources.
Back to top

azd init
Initialize a new app.
Synopsis
Initialize a new app.
When no template is supplied, you can optionally select an Azure Developer CLI template for cloning. Otherwise, azd init initializes the current directory and creates resources so that your project is compatible with Azure Developer CLI.
When a template is provided, the sample code is cloned to the current directory.
azd init [flags]

Options
  -b, --branch string         The template branch to initialize from.
  -e, --environment string    The name of the environment to use.
  -h, --help                  Gets help for init.
  -l, --location string       Azure location for the new environment
      --subscription string   Name or ID of an Azure subscription to use for the new environment
  -t, --template string       The template to use when you initialize the project. You can use Full URI, <owner>/<repository>, or <repository> if it's part of the azure-samples organization.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd login
Log in to Azure.
Synopsis
Log in to Azure.
When run without any arguments, log in interactively using a browser. To log in using a device code, pass
--use-device-code.
To log in as a service principal, pass --client-id and --tenant-id as well as one of: --client-secret,
--client-certificate, --federated-credential, or --federated-credential-provider.
azd login [flags]

Options
      --check-status                           Checks the log-in status instead of logging in.
      --client-certificate string              The path to the client certificate for the service principal to authenticate with.
      --client-id string                       The client id for the service principal to authenticate with.
      --client-secret string                   The client secret for the service principal to authenticate with. Set to the empty string to read the value from the console.
      --federated-credential string            The federated token for the service principal to authenticate with. Set to the empty string to read the value from the console.
      --federated-credential-provider string   The provider to use to acquire a federated token to authenticate with.
  -h, --help                                   Gets help for login.
  -o, --output string                          The output format (the supported formats are json, none). (default "none")
      --redirect-port int                      Choose the port to be used as part of the redirect URI during interactive login.
      --tenant-id string                       The tenant id for the service principal to authenticate with.
      --use-device-code                        When true, log in by using a device code instead of a browser.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd logout
Log out of Azure
Synopsis
Log out of Azure
azd logout [flags]

Options
  -h, --help   Gets help for logout.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd monitor
Monitor a deployed app.
Synopsis
Monitor a deployed app.
Examples:
	azd monitor --overview
	azd monitor -–live
	azd monitor --logs

For more information, go to https://aka.ms/azure-dev/monitor.
azd monitor [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for monitor.
      --live                 Open a browser to Application Insights Live Metrics. Live Metrics is currently not supported for Python apps.
      --logs                 Open a browser to Application Insights Logs.
      --overview             Open a browser to Application Insights Overview Dashboard.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd pipeline
Manage GitHub Actions or Azure Pipelines.
Synopsis
Manage GitHub Actions or Azure Pipelines.
The Azure Developer CLI template includes a GitHub Actions and an Azure Pipeline configuration file in the .github/workflows and .azdo/pipelines directories respectively. The configuration file deploys your app whenever code is pushed to the main branch.
For more information, go to https://aka.ms/azure-dev/pipeline.
Options
  -h, --help   Gets help for pipeline.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd pipeline config: Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
Back to top

azd pipeline config
Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
Synopsis
Create and configure your deployment pipeline by using GitHub Actions or Azure Pipelines.
For more information, go to https://aka.ms/azure-dev/pipeline.
azd pipeline config [flags]

Options
      --auth-type string        The authentication type used between the pipeline provider and Azure for deployment (Only valid for GitHub provider)
  -e, --environment string      The name of the environment to use.
  -h, --help                    Gets help for config.
      --principal-name string   The name of the service principal to use to grant access to Azure resources as part of the pipeline.
      --principal-role string   The role to assign to the service principal. (default "contributor")
      --provider string         The pipeline provider to use (github for Github Actions and azdo for Azure Pipelines). (default "github")
      --remote-name string      The name of the git remote to configure the pipeline to run on. (default "origin")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd pipeline: Manage GitHub Actions or Azure Pipelines.
Back to top

azd provision
Provision the Azure resources for an app.
Synopsis
Provision the Azure resources for an app.
The command prompts you for the following values:

Environment name: The name of your environment.
Azure location: The Azure location where your resources will be deployed.
Azure subscription: The Azure subscription where your resources will be deployed.

Depending on what Azure resources are created, running this command might take a while. To view progress, go to the Azure portal and search for the resource group that contains your environment name.
azd provision [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for provision.
      --no-progress          Suppresses progress information.
  -o, --output string        The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd restore
Restore app dependencies.
Synopsis
Restore app dependencies.
Run this command to download and install all the required libraries so that you can build, run, and debug the app locally.
For the best local run and debug experience, go to https://aka.ms/azure-dev/vscode to learn how to use the Visual Studio Code extension.
azd restore [flags]

Options
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for restore.
      --service string       Restores a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are restored).

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd template
Manage templates.
Options
  -h, --help   Gets help for template.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template list: List templates.
azd template show: Show the template details.
Back to top

azd template list
List templates.
azd template list [flags]

Options
  -h, --help            Gets help for list.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template: Manage templates.
Back to top

azd template show
Show the template details.
azd template show <template> [flags]

Options
  -h, --help            Gets help for show.
  -o, --output string   The output format (the supported formats are json, table). (default "table")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template: Manage templates.
Back to top

azd up
Initialize the app, provision Azure resources, and deploy your project with a single command.
Synopsis
Initialize the project (if the project folder has not been initialized or cloned from a template), provision Azure resources, and deploy your project with a single command.
This command executes the following in one step:
	azd init
	azd provision
	azd deploy

When no template is supplied, you can optionally select an Azure Developer CLI template for cloning. Otherwise, running azd up initializes the current directory so that your project is compatible with Azure Developer CLI.
azd up [flags]

Options
  -b, --branch string         The template branch to initialize from.
  -e, --environment string    The name of the environment to use.
  -h, --help                  Gets help for up.
  -l, --location string       Azure location for the new environment
      --no-progress           Suppresses progress information.
  -o, --output string         The output format (the supported formats are json, none). (default "none")
      --service string        Deploys a specific service (when the string is unspecified, all services that are listed in the azure.yaml file are deployed).
      --subscription string   Name or ID of an Azure subscription to use for the new environment
  -t, --template string       The template to use when you initialize the project. You can use Full URI, <owner>/<repository>, or <repository> if it's part of the azure-samples organization.

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

azd version
Print the version number of Azure Developer CLI.
azd version [flags]

Options
  -h, --help            Gets help for version.
  -o, --output string   The output format (the supported formats are json, none). (default "none")

Options inherited from parent commands
  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

Back to top

/check-enforcer evaluate

authors: azure-sdk wbreza

repo: Azure/azure-dev