Azure Pipelines Documentation

Welcome to Azure Pipelines

Azure Pipelines is a cloud service that you can use to automatically build, test, and deploy your code to any cloud or on-premises. It’s a component of Azure DevOps Services, but you can use it to deploy projects that are hosted anywhere.

This documentation provides a comprehensive guide to understanding and utilizing Azure Pipelines for your continuous integration and continuous delivery (CI/CD) needs.

Getting Started

Begin your journey with Azure Pipelines by setting up your first project and pipeline. Follow these steps:

  1. Create an Azure DevOps Organization: If you don't have one, sign up for free at Azure DevOps.
  2. Create a New Project: Within your organization, create a new project to house your code and pipelines.
  3. Connect to a Repository: Link your project to a source code repository (e.g., Azure Repos, GitHub, Bitbucket).
  4. Create Your First Pipeline: Use either the YAML editor or the classic editor to define your build and release processes.

Refer to the Pipeline Basics section for more on defining your pipeline.

Pipeline Basics

An Azure Pipeline is defined by a sequence of stages, jobs, and steps:

Azure Pipelines supports both YAML pipelines (recommended for modern development) and Classic Editor pipelines (a visual designer).

Key Features

Azure Pipelines offers a robust set of features including multi-platform builds, integration with various services, advanced deployment strategies, and comprehensive reporting.

YAML Pipelines

YAML pipelines allow you to define your CI/CD process as code, enabling versioning, auditing, and code reviews for your pipelines. This approach promotes a robust and repeatable deployment workflow.

A basic YAML pipeline structure might look like this:


trigger:
- main

pool:
  vmImage: 'ubuntu-latest'

stages:
- stage: Build
  jobs:
  - job: BuildJob
    steps:
    - script: echo Building the application!
      displayName: 'Run a one-line script'

    - task: CmdLine@2
      inputs:
        script: |
          echo Listing files
          dir
      displayName: 'Run a multi-line script'

- stage: Test
  dependsOn: Build
  jobs:
  - job: TestJob
    steps:
    - script: echo Running tests...
      displayName: 'Run Tests'
            

Explore detailed syntax and task references in the official Azure Pipelines documentation.

Classic Editor Pipelines

For those who prefer a visual interface, the Classic Editor provides a drag-and-drop experience to construct your build and release pipelines. This can be helpful for quick setup or for users less familiar with YAML syntax.

You can access the Classic Editor from your pipeline creation screen. While powerful, it's generally recommended to migrate to YAML for better source control and collaboration.

Integrations

Azure Pipelines integrates seamlessly with a wide array of services and tools:

Leverage these integrations to create a comprehensive and automated DevOps workflow.