Showing 30 question(s)
Answer:
Azure DevOps is Microsoft cloud-based DevOps platform that provides services for planning, developing, testing, deploying, and monitoring applications. It includes Azure Repos, Azure Pipelines, Azure Boards, Azure Artifacts, and Azure Test Plans.
Code Example:
# Azure CLI Login
az login
# List Azure DevOps organizations
az devops configure --defaults organization=https://dev.azure.com/YourOrganizationAnswer:
Azure DevOps consists of Azure Boards, Azure Repos, Azure Pipelines, Azure Test Plans, and Azure Artifacts for complete application lifecycle management.
Code Example:
Azure Boards
Azure Repos
Azure Pipelines
Azure Test Plans
Azure ArtifactsAnswer:
DevOps is a culture and set of practices that combines software development and IT operations to deliver applications faster, improve collaboration, and automate the software delivery lifecycle.
Code Example:
Plan
Code
Build
Test
Release
Deploy
Operate
MonitorAnswer:
Azure DevOps provides source control, CI/CD automation, agile planning, package management, testing, collaboration, security integration, and faster software delivery.
Code Example:
✔ Source Control
✔ CI/CD
✔ Agile Planning
✔ Testing
✔ ArtifactsAnswer:
An Azure DevOps Organization is the top-level container that stores projects, users, repositories, pipelines, boards, and other Azure DevOps resources.
Code Example:
Organization
├── Project A
├── Project B
└── Project CAnswer:
An Azure DevOps Project is a logical container that contains repositories, pipelines, boards, test plans, and artifacts for a specific application or solution.
Code Example:
Organization
└── Project
├── Repos
├── Pipelines
├── Boards
├── Test Plans
└── ArtifactsAnswer:
Azure Repos is Azure DevOps source control service that provides unlimited Git repositories or Team Foundation Version Control (TFVC) repositories.
Code Example:
git clone https://dev.azure.com/organization/project/_git/repositoryAnswer:
Azure Boards is a work tracking service that helps teams plan, assign, track, and manage work items such as Epics, Features, User Stories, Tasks, and Bugs.
Code Example:
Epic
└── Feature
└── User Story
└── TaskAnswer:
Azure Pipelines is a CI/CD service that automates building, testing, and deploying applications to various environments.
Code Example:
trigger:
- main
pool:
vmImage: ubuntu-latest
steps:
- script: echo "Hello Azure DevOps"Answer:
Azure Artifacts is a package management service used to create, host, and share NuGet, npm, Maven, Python, and Universal packages across development teams.
Code Example:
# Restore NuGet packages
dotnet restore
# Publish package
dotnet nuget push package.nupkgAnswer:
Azure Repos is a source control service in Azure DevOps that provides Git and Team Foundation Version Control (TFVC) repositories for storing and managing source code.
Code Example:
git clone https://dev.azure.com/organization/project/_git/repositoryAnswer:
Git is a distributed version control system where every developer has a complete copy of the repository, whereas TFVC is a centralized version control system where code is stored on a central server.
Code Example:
# Git Repository
git clone <repository-url>
# TFVC Workspace
tf workspaceAnswer:
Use the git clone command followed by the Azure Repos repository URL.
Code Example:
git clone https://dev.azure.com/organization/project/_git/MyRepositoryAnswer:
Branch Policies enforce code quality by requiring pull requests, reviewers, successful builds, work item linking, and other validation checks before merging into protected branches.
Code Example:
Main Branch
✔ Minimum Reviewers
✔ Build Validation
✔ Linked Work Items
✔ Comment ResolutionAnswer:
A Pull Request is a request to merge changes from one branch into another. It enables code reviews, discussions, automated validation, and approval before merging.
Code Example:
Feature Branch
│
▼
Pull Request
│
▼
Main BranchAnswer:
Code Review is the process of reviewing source code changes through Pull Requests before they are merged, helping improve code quality and reduce defects.
Code Example:
Developer
│
▼
Create PR
│
▼
Reviewer Approval
│
▼
MergeAnswer:
Protect the main branch by configuring branch policies such as mandatory reviewers, build validation, merge checks, and restricting direct pushes.
Code Example:
Project Settings
→ Repositories
→ Branches
→ Branch PoliciesAnswer:
Build Validation automatically runs a build pipeline when a Pull Request is created to ensure the code compiles and passes tests before merging.
Code Example:
Pull Request
│
▼
Build Pipeline
│
▼
Success ✔
│
▼
MergeAnswer:
Azure Repos supports permissions such as Read, Contribute, Create Branch, Create Tag, Force Push, Manage Permissions, and Delete Repository.
Code Example:
✔ Read
✔ Contribute
✔ Create Branch
✔ Create Tag
✔ Force PushAnswer:
Use feature branches, protect the main branch, require pull requests, enable build validation, write meaningful commit messages, and review code before merging.
Code Example:
✔ Feature Branches
✔ Pull Requests
✔ Branch Policies
✔ Build Validation
✔ Code ReviewsAnswer:
Azure Pipelines is a CI/CD service in Azure DevOps that automates the process of building, testing, and deploying applications to various environments.
Code Example:
trigger:
- main
pool:
vmImage: ubuntu-latest
steps:
- script: echo "Build Started"Answer:
Continuous Integration is the practice of automatically building and testing code whenever developers commit changes to the repository.
Code Example:
trigger:
- main
steps:
- task: DotNetCoreCLI@2
inputs:
command: buildAnswer:
Continuous Deployment automatically deploys successfully built applications to target environments after passing all validation checks.
Code Example:
stages:
- stage: Build
- stage: DeployAnswer:
A YAML Pipeline defines the build and deployment process as code using a YAML file stored in the source repository.
Code Example:
trigger:
- main
pool:
vmImage: ubuntu-latest
steps:
- script: dotnet buildAnswer:
Classic Pipelines are created using a graphical interface, whereas YAML Pipelines store pipeline definitions as code, making them version-controlled and easier to maintain.
Code Example:
Classic Pipeline
✔ GUI Based
YAML Pipeline
✔ Code Based
✔ Version ControlledAnswer:
Stages divide a pipeline into logical sections such as Build, Test, and Deploy. Each stage can contain multiple jobs.
Code Example:
stages:
- stage: Build
- stage: Test
- stage: DeployAnswer:
A Job is a collection of steps that run sequentially on the same build agent.
Code Example:
jobs:
- job: BuildJob
steps:
- script: dotnet buildAnswer:
A Task is the smallest unit of work in a pipeline. Tasks perform operations such as restoring packages, building code, running tests, or deploying applications.
Code Example:
steps:
- task: DotNetCoreCLI@2
inputs:
command: publishAnswer:
A Build Agent is a machine or virtual machine that executes pipeline jobs. Azure DevOps supports Microsoft-hosted agents and self-hosted agents.
Code Example:
pool:
vmImage: windows-latestAnswer:
Microsoft-hosted agents are managed by Microsoft and come preconfigured with common development tools. Self-hosted agents are installed and maintained by your organization, providing greater control over the execution environment.
Code Example:
pool:
vmImage: ubuntu-latest
# OR
pool:
name: SelfHostedAgentPool