Episode 143–Azure Pipelines - a podcast by The 6 Figure Developer
from 2020-05-11T13:11:44
In this episode we talk about Azure Pipelines.
DefinitionsWhat is a pipeline
Chain of repeatable actions/tasks that transform some input into some output. Its like afunction chain.
Types of pipelinesBuild Pipeline
This pipeline takes the source code as input and produces deployable artifacts as the output.It may also do some unit testing, linting and static analysis to the code to check the validatiy of the output artifacts.
Release PiplelineThis pipeline takes the deployable artifacts as input and produces deployed environments as outputs.
It may also perform some automated integration tests to test the validity of the deploymentContinuous Integration (CI)
This is the practice of merging the small batches of developer changes into the main branch continuously instead of all at once at the end of a development cycle.This is facilitated by a good build pipeline.
For good or worse CI Pipeline and Build Pipeline are often conflatedContinuous Delivery (CD)
This is the practice of automatically deploying an artifact to an environment as soon as the artifact is created.This does not mean that the environment production.
This is facilitated by a good release pipelineFor good or worse CD Pipeline and Release Pipeline are often conflated
CI/CDThis is when we combine the practice of Continuous Integration with the practice of Continuous Delivery
Continuous DeploymentThis is the practice of extending the automatic deployment of an artifact through all stages until is automatically deployed to production.
This requires one or more good release pipelines
It often gets confused with Continious Delivery. It is Continuous Delivery but Continuous Delivery is not Continuous Deployment.Azure DevOps Products
Azure DevOpsA suite of development tools
Azure PipelinesTool for building out the build and release pipelines
Alternates Jenkins, Octopus, TeamCity, Circleci, GitLabExcellent GitHub and Azure DevOps Repos integration, but can connect to other remote repositories
Excellent Azure integration, but can deploy into most any platfor or environment.Linux, macOS and Windows adjents
Supports most lanuagesFree for Open Source (10 parallel jobs unlimited minutes)
First agent free for closed sourceBefore Creating a Pipeline
Consider your branching strategyRecommend, Trunk-based Strategy
Team shares single trunk (master) that all development is based off of.Release Flow
Creating a Build PipelineYAML vs Classic
Recommend, YAML uses a yaml config stored in the source code repository to define the build pipeline.Classic is good for learning the platform and can be used to figure out the correct yaml.
triggerRecommend, based on changes to specified branchs
can include or exclude files and folders within the branchcan be triggered on a timed schedule
define jobsa job us run on an agent and has its own variables and copies of source code etc.jobs can be completed in parallel
define steps in jobssteps are the collection of steps/tasks that a given job will run
define the task in stepeach step is a task
this will be the heart of your build pipeline and will depend largely on what you are buildingvariables
you may want to specify some variables across jobs, like version numberpools
you many want to specify the type of agent to use by default instead of in every job definitionCreating a Release Pipeline
ClassicThe “only released” method for creating a release pipeline is the classic method
You could create a yaml build pipeline that performed the release tasks but triggers might be more challenging.Recommend, There are some other options in pre-release.
select artifactsthis will likely come from artifacts published from a build pipeline
Further episodes of The 6 Figure Developer Podcast
Further podcasts by The 6 Figure Developer
Website of The 6 Figure Developer