Do you have a healthy CI/CD pipeline? Do releases simply flow through? CI, CD, PRs, Pipelines, Releases, Deployments and all that jazz.
Whether you're new to Continuous Delivery or a hardened traveller down that road, this session has something for you. We’ll start with an exploration of branching strategy (releaseflow.org) before walking through a healthy continuous delivery configuration.
We’ll watch a code change make it's way through a pipeline to production and discuss how we can apply such practices to our everyday work.
2. About me
● Programmer @DiligentSoft
○ Currently @DVLAgovuk with @notbinary_
● Husband, father, gym-goer, musician.
● Volunteer @CodeClub, @Cornerstone_CS
● Member of @SwanseaSDC and #hackthecity communities
● Enjoy Football, Running, Scuba Diving
5. “Arguing with an engineer is like wrestling in the
mud with a pig. After a couple of hours you realize
the pig likes it.”
gineersnow.com/engineering/engineers-love-argue
9. “Developers Who Use Spaces Make More Money
Than Those Who Use Tabs”
stackoverflow.blog/2017/06/15/developers-use-spaces-make-money-use-tabs/
10. “Choose tabs, choose spaces… It doesn't actually matter which coding styles
you pick. What does matter is that you, and everyone else on your team, sticks
with those conventions and uses them consistently...
Jeff Atwood
blog.codinghorror.com/death-to-the-space-infidels/
That said, only a moron would use tabs to format their code.”
18. Build, release and deploy
● Build steps include compile, test, package and publish
○ Publish artifact ready for deployment
● Release is a special build to publish an immutable version of software
○ Tag repository with version and publish release version of artifact ready for deployment
● Deploy steps deliver published artifact to an environment
○ Delivers a certain version to a specific environment
○ No environment-specific builds: the artifact should not be built again.
30. The development community is woke
GitHub Flow scottchacon.com/2011/08/31/github-flow.html
GitFlow considered harmful endoflineblog.com/gitflow-considered-harmful
Follow-up to 'GitFlow considered harmful'
endoflineblog.com/follow-up-to-gitflow-considered-harmful
Still using GitFlow? What about a simpler alternative?
hackernoon.com/still-using-gitflow-what-about-a-simpler-alternative-74aa9a46b9a3
Branching Is Easy. So? Git-flow Is Not Agile.
www.elidedbranches.com/2013/02/branching-is-easy-so.html
A real-life git workflow. Why git flow does not work for us
luci.criosweb.ro/a-real-life-git-workflow-why-git-flow-does-not-work-for-us/
31. Release Branching Strategy
Recommended approach to branching in the book "Continuous Delivery: Reliable
Software Releases through Build, Test, and Deployment Automation" by Jez
Humble and David Farley (2010).
41. Tagging
A release tag should use a three segment number as defined in Semantic Versioning 2.0.0:
● MAJOR version when you make incompatible API changes,
● MINOR version when you add functionality in a backwards-compatible manner, and
● PATCH version when you make backwards-compatible bug fixes.
53. Automate release notes
● Enforce ticket reference in commit messages
○ Start with regex
○ Finish up with lookup to validate ticket exists in ALM tool
● Generate release notes
○ Create release notes during release steps in Jenkins
○ Use ticket references from commit messages
○ Enrich with story data using ALM tool API
55. Acceptance Tests
● Do automate your acceptance tests
○ Critical to continuous delivery pipeline
○ Unless automated tests can run in your pipeline they’re not valuable enough
● Make tests configurable for any environment
● Definition of done for stories must include acceptance tests
● Do include smoke tests
● Group acceptance test suites for fast feedback
57. Deployment
● Automate, duh!
● Use acceptance tests of upstream deployments as gate for deployments to
downstream environments
● Prefer environment variables to configure applications
○ 12 factor app anyone?
○ Inject environment-specifics into application packages during deployment where necessary