Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Accelerating Continuous delivery with DORA, Clo...

Accelerating Continuous delivery with DORA, Cloud Deploy and JFrog Pipelines

Swampup 2022

cncf-canada-meetups

May 26, 2022
Tweet

More Decks by cncf-canada-meetups

Other Decks in Education

Transcript

  1. Accelerating Continuous delivery with DORA, Cloud Deploy & Jfrog Pipelines

    Archy - Hybrid Cloud CE @Google Cloud Canada Jenn viau - Cloud Engineering @PwC Canada
  2. ACME Co. A biking shop in trouble • Slow innovation

    • High Operational Costs • Security Concerns • Long Lead time for changes
  3. Online Bike Shop • 11 Services • 1 Team •

    2 Months URL: http://store-dev.automateit.ca/
  4. Online Bike Shop Deployment • Manual build • Manual deployment

    • Dev -> Stg -> Prod Source code repo: https://github.com/gdg-cloud-montreal/online-boutique
  5. • Started by Gene Kim, Jez Humble & Puppet •

    First to look at 4 key metric • Key technical practices and obstacles to adoption 2013 State of DevOps Report 2014 State of DevOps Report • Phd Nicole Forsgren joined the project • Largest survey to date • Companies with high… performance are twice as likely to exceed their profitability, market share and productivity goals” • Speed and stability are not a trade-off
  6. Deployment frequency Lead time for changes Software Delivery & Operations

    Performance Time to restore service Change fail rate (%) Speed Stability
  7. Elite performers vs Low Yes, you read correctly. This is

    not an error. more frequent code deployments faster lead time to deploy lower change failure rate (changes are 1/3 as likely to fail) faster time to recover from incidents
  8. bfd

  9. Less Rework Technical Practices Test Automation Continuous Testing Deployment Automation

    Version Control Trunk-based Development Test Data Management Shift Left on Security Monitoring & Observability Loosely Coupled Architecture Proactive Notifications Empowered Teams Code Maintainability Database Change Management Continuous Integration Continuous Delivery
  10. Transformational Leadership Less Rework Technical Practices Test Automation Continuous Testing

    Deployment Automation Version Control Trunk-based Development Test Data Management Shift Left on Security Monitoring & Observability Loosely Coupled Architecture Proactive Notifications Empowered Teams Code Maintainability Database Change Management Continuous Integration Continuous Delivery
  11. Transformational Leadership Vision Inspirational Communication Intellectual Stimulation Supportive Leadership Personal

    Recognition Less Rework Technical Practices Test Automation Continuous Testing Deployment Automation Version Control Trunk-based Development Test Data Management Shift Left on Security Monitoring & Observability Loosely Coupled Architecture Proactive Notifications Empowered Teams Code Maintainability Database Change Management Continuous Integration Continuous Delivery
  12. Transformational Leadership Vision Inspirational Communication Intellectual Stimulation Supportive Leadership Personal

    Recognition Less Rework Technical Practices Test Automation Continuous Testing Deployment Automation Version Control Trunk-based Development Test Data Management Shift Left on Security Monitoring & Observability Loosely Coupled Architecture Proactive Notifications Empowered Teams Code Maintainability Database Change Management Continuous Integration Continuous Delivery Less Rework
  13. Online Bike Shop Deployment • Automate build • Manual deployment

    • Dev -> Stg -> Prod Source code repo: https://github.com/gdg-cloud-montreal/online-boutique
  14. Using CI tools for Continuous Delivery Source Image Dev Env

    Manifest Render Deploy to Dev Build (CI) Delivery (CD) Stg Env Manifest Render Deploy to Stg $ bash $ bash $ bash $ bash
  15. CD with Kubernetes is a Journey Pipeline Changes Scale /

    Maturity Multi-environment Static config Scripted Manifest Rendering Manifest Rendering Products Advanced CD Techniques: • Approvals • Audit • Rollback • Blue-Green • Canary
  16. Google Cloud Deploy • Fully-managed and scalable • Easy integration

    with CI tools • Control and measurability (e.g. DORA) • Provides built-in security controls
  17. Google Cloud Deploy - How it works? Dev K8s Cluster

    Cloud Deploy UI Stg K8s Cluster Prod K8s Cluster … Setup Cloud Deploy Pipeline Configure K8s Targets Delivery (CD) # cd.yaml apiVersion: deploy.cloud kind: delivery-pipeline serialPipeline: stages: - targetId: dev-cluster profiles: - skaffold-dev ... - targetId: stg-cluster profiles: - skaffold-stg # target.yaml apiVersion: deploy.cloud kind: target metadata: name: dev-cluster requireApproval: false gke: cluster: /location/clusters/shop-dev $ gcloud deploy apply --file cd.yaml $ gcloud deploy apply --file cd-targets.yaml
  18. Google Cloud Deploy - How it works? Dev K8s Cluster

    Cloud Deploy UI Stg K8s Cluster Prod K8s Cluster … Build (CI) gcloud deploy releases Update CI Pipeline with Release to CD Delivery (CD)
  19. Google Cloud Deploy - How it works? Rendering choice Dev

    K8s Cluster Cloud Deploy UI Stg K8s Cluster Prod K8s Cluster … Render Manage Deployment Targets deploy store Build (CI) deploy output.yaml release Delivery (CD)
  20. Render manifests Replace image references in manifests with the pushed

    image $ skaffold render output.yaml Store apiVersion: skaffold/v2beta38 kind: Config … deploy: kubectl: manifests: - ./adservice.yaml … profiles: -name: dev deploy: helm: releases: - name:checkout-chart remoteChart:jfrog.io/bikeshop/checkout valuesFiles: - ./charts/dev-values.yaml -name: stg -name: prod • Cloud-Native Developer Productivity Tool • Declarative, Portable Config
  21. Google Cloud Deploy - How it works? Rendering choice Dev

    K8s Cluster Cloud Deploy UI • Promote Rollout • DIFF & Blame • Monitor Rollout • Rollback • Dora Metrics Stg K8s Cluster Prod K8s Cluster … Render Manage Deployment Targets deploy store Build (CI) deploy output.yaml release $ skaffold apply output-dev.yaml
  22. Online Bike Shop v3 • Changes trigger deployment to dev

    • Promote releases • Rollback on failures • Change logs URL: http://store.automateit.ca/
  23. Online Bike Shop Team after 4 months of improvements •

    11 Microservices • 7 Teams • Dora Metrics: ◦ Deployment Frequency: B/n once per hour and once per day ◦ Time to restore service: Less than one hour ◦ Change fail rate: 0–15% • Outcomes: ◦ Deployment during office hours (Less Burnout) ◦ Less Stress ◦ Less Deployment Pain
  24. The 4 Dora Key Metrics are the outcomes! • They

    show where are you compare to your industry • They provide data-driven business improvements • They measured at the team level • You don’t need to trade off speed for stability Deployment frequency Lead time for changes Time to restore service Change fail rate Speed Stability
  25. The 4 Dora Key Metrics are the outcomes! • They

    show where are you compare to your industry • They provide data-driven business improvements • They measured at the team level • You don’t need to trade off speed for stability Deployment frequency Lead time for changes Time to restore service Change fail rate Speed Stability
  26. Proprietary + Confidential It takes work. We don’t have to

    do it all at once. will probably fail if we try
  27. SHOWNOTES: • Our Slides: • CI Repo - github.com/gdg-cloud-montreal/online-boutique •

    CD Repo - github.com/gdg-cloud-montreal/swampup-2022 Jenn Viau Director, Cloud Engineering @PWC Ayrat Khayretdinov CNCF Ambassador, CE @Google Cloud @jennviau @archyufa
  28. Thank you! Jenn Viau Director, Cloud Engineering @PWC Ayrat Khayretdinov

    CNCF Ambassador, CE @Google Cloud @jenn_viau @archyufa