Get started using Azure Developer CLI

Run a Node.js template

Let's put the basic Azure Developer CLI (azd) commands to the test and run one of our Node.js template applications. We'll use the React Web App with Node.js API and MongoDB on Azure for this guide.

Upon completion, you'll get the code in your development environment and be able to run commands to build, deploy, and monitor the app in Azure.

Select your preferred environment to continue:

Prerequisites

Initialize the project

  1. In File Explorer or a terminal, create a new empty directory, and change into it.

  2. Run the azd init command and specify the template you want to use as a parameter:

    azd init --template todo-nodejs-mongo
    

Note: this command will initialize the application, including cloning the GitHub repo.

  1. You will be prompted for an environment name, which sets the prefix for the resource group that will be created to hold the Azure resources. What is an Environment Name in azd?

After you specify the environment, azd clones the template project to your machine and initializes the project.

Provision and deploy the app resources

  1. Run the azd up command:

    azd up
    
  2. If you are not already signed-in to Azure, the browser will launch and ask you to sign-in.

  3. Once you are signed-in to Azure, you will be prompted for the following information:

Parameter Description
Azure Location The Azure location where your resources will be deployed.
Azure Subscription The Azure Subscription where your resources will be deployed.

After you provide these values, the azd up command:

  • Creates and configures all necessary Azure resources (azd provision), including:
    • Access policies and roles for your account
    • Service-to-service communication with Managed Identities
  • Packages and deploys the code (azd deploy)

When the azd up command completes successfully, the CLI displays two links to view resources created:

  • ToDo API app
  • ToDo web app frontend

Screenshot of command output listing endpoint URLs.

Note

You can call azd up as many times as you like to both provision and deploy updates to your application.

Run a Python template

Let's put the basic Azure Developer CLI (azd) commands to the test and run one of our Python template applications. We'll use the React Web App with Python API and MongoDB on Azure for this guide.

Upon completion, you'll get the code in your development environment and be able to run commands to build, deploy, and monitor the app in Azure.

Select your preferred environment to continue:

Pre-requisites

Create and activate a Python virtual environment

In this guide, the app uses Python Virtual Environments to isolate Python package installations. Start by creating and activating a virtual environment.

Initialize the project

  1. In File Explorer or a terminal, create a new empty directory, and change into it.

  2. Run the azd init command and specify the template you want to use as a parameter:

    azd init --template todo-python-mongo
    

Note: this command will initialize the application, including cloning the GitHub repo.

  1. You will be prompted for an environment name, which sets the prefix for the resource group that will be created to hold the Azure resources. What is an Environment Name in azd?

After you specify the environment, azd clones the template project to your machine and initializes the project.

Provision and deploy the app resources

  1. Run the azd up command:

    azd up
    
  2. If you are not already signed-in to Azure, the browser will launch and ask you to sign-in.

  3. Once you are signed-in to Azure, you will be prompted for the following information:

Parameter Description
Azure Location The Azure location where your resources will be deployed.
Azure Subscription The Azure Subscription where your resources will be deployed.

After you provide these values, the azd up command:

  • Creates and configures all necessary Azure resources (azd provision), including:
    • Access policies and roles for your account
    • Service-to-service communication with Managed Identities
  • Packages and deploys the code (azd deploy)

When the azd up command completes successfully, the CLI displays two links to view resources created:

  • ToDo API app
  • ToDo web app frontend

Screenshot of command output listing endpoint URLs.

Note

You can call azd up as many times as you like to both provision and deploy updates to your application.

Run a C# template

Let's put the basic Azure Developer CLI (azd) commands to the test and run one of our C# template applications. We'll use the React Web App with C# API and MongoDB on Azure for this guide.

Upon completion, you'll get the code in your development environment and be able to run commands to build, deploy, and monitor the app in Azure.

Select your preferred environment to continue:

Pre-requisites

Initialize the project

  1. In File Explorer or a terminal, create a new empty directory, and change into it.

  2. Run the azd init command and specify the template you want to use as a parameter:

    azd init --template todo-csharp-cosmos-sql
    

Note: this command will initialize the application, including cloning the GitHub repo.

  1. You will be prompted for an environment name, which sets the prefix for the resource group that will be created to hold the Azure resources. What is an Environment Name in azd?

After you specify the environment, azd clones the template project to your machine and initializes the project.

Provision and deploy the app resources

  1. Run the azd up command:

    azd up
    
  2. If you are not already signed-in to Azure, the browser will launch and ask you to sign-in.

  3. Once you are signed-in to Azure, you will be prompted for the following information:

Parameter Description
Azure Location The Azure location where your resources will be deployed.
Azure Subscription The Azure Subscription where your resources will be deployed.

After you provide these values, the azd up command:

  • Creates and configures all necessary Azure resources (azd provision), including:
    • Access policies and roles for your account
    • Service-to-service communication with Managed Identities
  • Packages and deploys the code (azd deploy)

When the azd up command completes successfully, the CLI displays two links to view resources created:

  • ToDo API app
  • ToDo web app frontend

Screenshot of command output listing endpoint URLs.

Note

You can call azd up as many times as you like to both provision and deploy updates to your application.

Run a Java template

Let's put the basic Azure Developer CLI (azd) commands to the test and run one of our Java template applications. We'll use the React Web App with Java API and MongoDB on Azure for this guide.

Upon completion, you'll get the code in your development environment and be able to run commands to build, deploy, and monitor the app in Azure.

Select your preferred environment to continue:

Pre-requisites

Initialize the project

  1. In File Explorer or a terminal, create a new empty directory, and change into it.

  2. Run the azd init command and specify the template you want to use as a parameter:

    azd init --template todo-java-mongo
    

Note: this command will initialize the application, including cloning the GitHub repo.

  1. You will be prompted for an environment name, which sets the prefix for the resource group that will be created to hold the Azure resources. What is an Environment Name in azd?

After you specify the environment, azd clones the template project to your machine and initializes the project.

Provision and deploy the app resources

  1. Run the azd up command:

    azd up
    
  2. If you are not already signed-in to Azure, the browser will launch and ask you to sign-in.

  3. Once you are signed-in to Azure, you will be prompted for the following information:

Parameter Description
Azure Location The Azure location where your resources will be deployed.
Azure Subscription The Azure Subscription where your resources will be deployed.

After you provide these values, the azd up command:

  • Creates and configures all necessary Azure resources (azd provision), including:
    • Access policies and roles for your account
    • Service-to-service communication with Managed Identities
  • Packages and deploys the code (azd deploy)

When the azd up command completes successfully, the CLI displays two links to view resources created:

  • ToDo API app
  • ToDo web app frontend

Screenshot of command output listing endpoint URLs.

Note

You can call azd up as many times as you like to both provision and deploy updates to your application.

Clean up resources

When you no longer need the resources created in this article, run the following command to power down the app:

azd down

Request help

For information on how to file a bug, request help, or propose a new feature for the Azure Developer CLI, please visit the troubleshooting and support page.

Next steps