Catalog / Azure DevOps & Cloud Cheat Sheet

Azure DevOps & Cloud Cheat Sheet

A comprehensive cheat sheet covering essential Azure DevOps and Cloud concepts, services, and commands.

Azure Fundamentals

Core Concepts

Azure Resource Manager (ARM): The deployment and management service for Azure. It enables you to create, update, and delete resources in your Azure subscription.

Resource Groups: Containers that hold related resources for an Azure solution. They provide a way to manage related resources as a unit.

Azure Resources: Manageable items available through Azure, such as virtual machines, storage accounts, web apps, databases, and virtual networks.

Azure Subscriptions: A logical container for your Azure resources. It provides a defined boundary for billing, access control, and resource limits.

Azure Regions: Geographical locations around the world where Azure datacenters are located. Choose regions based on proximity to users, compliance requirements, and service availability.

Azure CLI Basics

az login

Log in to your Azure account.

az account set --subscription <subscription_id>

Set the active Azure subscription.

az group create --name <resource_group_name> --location <location>

Create a new resource group.

az group delete --name <resource_group_name>

Delete a resource group.

az vm create --resource-group <resource_group_name> --name <vm_name> --image <image_name> --admin-username <username> --generate-ssh-keys

Create a new virtual machine (Linux).

Azure Portal Navigation

  • Home: Provides a dashboard view of your Azure resources and services.
  • All Services: A comprehensive list of all available Azure services.
  • Resource Groups: Access and manage your resource groups.
  • Virtual Machines: Access and manage your virtual machines.
  • Marketplace: Browse and deploy pre-configured solutions and services.

Azure DevOps Services

Azure Boards

Work Items: Represent tasks, bugs, features, and other work to be tracked.
Boards: Kanban-style boards for visualizing and managing work items.
Sprints: Short, time-boxed periods during which a set amount of work is completed.
Backlogs: Prioritized lists of work items to be completed.
Queries: Used to filter and find work items based on various criteria.

Azure Pipelines

Pipelines:

Automated workflows for building, testing, and deploying code.

YAML:

Define pipelines using YAML files for version control and repeatability.

Agents:

Compute infrastructure used to run pipeline jobs.

Tasks:

Reusable components that perform specific actions in a pipeline (e.g., build, test, deploy).

Triggers:

Events that start a pipeline run (e.g., code commit, scheduled time).

Example YAML pipeline:

trigger:
  - main

pool:
  vmImage: 'ubuntu-latest'

steps:
  - script: echo 'Hello, world!'
    displayName: 'Run a script'

Azure Repos

Git Repositories: Host private Git repositories for source code management.
Branches: Isolate development work on separate branches.
Pull Requests: Collaborate on code changes through pull requests.
Code Reviews: Review code changes before merging them into the main branch.
Policies: Enforce code quality and security standards through branch policies.

Azure Compute Services

Virtual Machines

Virtual Machine (VM):

An on-demand, scalable computing resource. You have full control over the OS and software installed.

VM Scale Sets:

Allows you to create and manage a group of identical VMs. Scale automatically based on demand.

az vm create

Create a new virtual machine.

az vm stop

Stop a virtual machine.

az vm start

Start a virtual machine.

az vm delete

Delete a virtual machine.

Azure Container Instances (ACI)

ACI offers the fastest way to run a container in Azure, without managing any VMs. It’s suitable for event-driven applications, background jobs, and simple applications.

az container create --resource-group <group_name> --name <container_name> --image <image_name> --cpu 1 --memory 1

Azure Kubernetes Service (AKS)

Kubernetes:

A container orchestration platform for automating deployment, scaling, and management of containerized applications.

AKS:

A managed Kubernetes service that simplifies deploying and managing Kubernetes clusters in Azure.

az aks create

Create a new AKS cluster.

az aks get-credentials

Get credentials to access the AKS cluster.

kubectl

The Kubernetes command-line tool for managing Kubernetes clusters.

Azure Storage Services

Storage Account Types

General-purpose v2: Standard storage account type for most scenarios, supporting blobs, files, queues, and tables.
BlockBlobStorage: Premium performance storage account for block blobs.
FileStorage: Premium performance storage account for Azure Files.

Blob Storage

Block Blobs:

Store unstructured data like text or binary files. Optimized for streaming and storing large objects.

Page Blobs:

Store random access files up to 8 TB in size. Used for virtual machine disks.

Append Blobs:

Store log data. Optimized for append operations.

az storage blob upload

Upload a file to Blob storage.

az storage blob download

Download a file from Blob storage.

Azure Files

Offers fully managed file shares in the cloud that are accessible via the industry standard SMB protocol. Azure Files can be mounted concurrently by cloud or on-premises deployments of Windows, Linux, and macOS.

az storage share create --account-name <account_name> --name <share_name>