How to Install Azure CLI (AZ) on Ubuntu 24.04 | Step-by-Step Guide

23K views Oct 16, 2024
linuxtechi.com

In this video tutorial, we will show you how to install Azure CLI (AZ), also known as the AZ command-line tool, on Ubuntu 24.04. Whether you're a beginner or an experienced user, this guide will help you set up and start using Azure CLI on your Linux system. **Steps Covered in this Video:** 1. **Update Package List** - Learn how to update your package list to ensure your system is ready for new installations. - Command: `sudo apt update` 2. **Install Required Dependencies** - We will install essential dependencies like `curl` and `apt-transport-https`. - Command: `sudo apt install curl apt-transport-https ca-certificates gnupg lsb-release -y` 3. **Add the Microsoft Repository** - Since the Azure CLI package is not available in the default Ubuntu repositories, we will add the Microsoft apt repository. - Add GPG Key: curl -sL https://packages.microsoft.com/keys/microsoft.asc | sudo gpg --dearmor -o /usr/share/keyrings/microsoft-archive-keyring.gpg - Add the Azure CLI repository: echo "deb [arch=amd64 signed-by=/usr/share/keyrings/microsoft-archive-keyring.gpg] https://packages.microsoft.com/repos/azure-cli/ $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/azure-cli.list