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

Kubernetes Blue-Green Deployment Made Easy with Argo Rollouts - ADDO

Kubernetes Blue-Green Deployment Made Easy with Argo Rollouts - ADDO

Hossam Barakat

October 27, 2021
Tweet

More Decks by Hossam Barakat

Other Decks in Programming

Transcript

  1. Kubernetes Blue-Green Deployment
    Made Easy with Argo Rollouts
    Hossam Barakat
    Engineering Manager at Willow
    @hossambarakat_ | www.hossambarakat.net

    View full-size slide

  2. @hossambarakat_
    • What is Argo Rollouts
    • Argo Rollouts Concepts
    • Blue-Green Deployment
    • Canary Deployment
    Agenda

    View full-size slide

  3. @hossambarakat_
    Deployment
    ReplicaSet
    Deployment
    Pod Pod

    View full-size slide

  4. @hossambarakat_
    • RollingUpdate
    • Recreate
    K8s Deployment Strategies

    View full-size slide

  5. @hossambarakat_
    Deployment Strategy - RollingUpdate
    Deployment
    ReplicaSet V2
    Pod Pod
    ReplicaSet V1
    Pod Pod

    View full-size slide

  6. @hossambarakat_
    Deployment Strategy - Recreate
    Deployment
    ReplicaSet V2
    Pod Pod
    ReplicaSet V1
    Pod Pod

    View full-size slide

  7. @hossambarakat_
    • Limited controls over the speed of the rollout
    • Inability to control traffic flow to the new version
    • No ability to query external metrics to verify an
    update
    • Unable to automatically abort and rollback the
    update
    K8s Deployment Challenges

    View full-size slide

  8. @hossambarakat_
    • Argo Rollouts is a Kubernetes controller and set
    of CRDs which provide advanced deployment
    capabilities such as blue-green, canary, canary
    analysis, experimentation, and progressive delivery
    features to Kubernetes.
    What is Argo Rollouts?

    View full-size slide

  9. @hossambarakat_
    • Controller and Custom Resource Definitions (CRDs)
    $ kubectl create namespace argo-rollouts
    $ kubectl apply -n argo-rollouts -f install.yaml
    • Kubectl argo rollouts plugin
    $ brew install argoproj/tap/kubectl-argo-rollouts
    $ kubectl argo rollouts version
    Installation

    View full-size slide

  10. @hossambarakat_
    • A drop-in replacement for a Deployment resource.
    • Provides additional blue-green and canary update
    strategies.
    • Automates promotion and rollback based on analysis
    results.
    Rollout

    View full-size slide

  11. @hossambarakat_
    Rollout
    ReplicaSet
    Deployment
    Pod Pod
    Rollout

    View full-size slide

  12. @hossambarakat_

    View full-size slide

  13. @hossambarakat_
    Blue-Green Rollout

    View full-size slide

  14. @hossambarakat_
    Blue-Green Rollout
    Users

    View full-size slide

  15. @hossambarakat_
    Blue-Green Rollout
    Users

    View full-size slide

  16. @hossambarakat_
    Blue-Green Rollout
    ReplicaSet
    Rollout
    Pod Pod
    Service
    Ingress

    View full-size slide

  17. @hossambarakat_
    Blue-Green Rollout
    Rollout
    ReplicaSet V2
    Pod Pod
    ReplicaSet V1
    Pod Pod
    Active Service
    Ingress
    Preview Service

    View full-size slide

  18. @hossambarakat_

    View full-size slide

  19. @hossambarakat_
    Canary Rollout

    View full-size slide

  20. @hossambarakat_
    Canary Rollout
    Users

    View full-size slide

  21. @hossambarakat_
    Canary Rollout
    Users

    View full-size slide

  22. @hossambarakat_
    Canary Rollout
    Users

    View full-size slide

  23. @hossambarakat_
    Canary Rollout
    Users

    View full-size slide

  24. @hossambarakat_
    Canary Rollout
    Users

    View full-size slide

  25. @hossambarakat_
    Traffic Provider Integrations
    Optional

    View full-size slide

  26. @hossambarakat_
    Rollout Canary with NGINX
    Rollout
    ReplicaSet V2
    Pod Pod
    ReplicaSet V1
    Pod Pod
    Stable Service
    Ingress
    Canary Service
    Canary Ingress

    View full-size slide

  27. @hossambarakat_
    Rollout Canary with NGINX
    Rollout
    ReplicaSet V2
    Pod Pod
    ReplicaSet V1
    Pod Pod
    Stable Service
    Ingress
    Canary Service
    Canary Ingress

    View full-size slide

  28. @hossambarakat_
    Rollout Canary with NGINX
    Rollout
    ReplicaSet V2
    Pod Pod
    ReplicaSet V1
    Pod Pod
    Stable Service
    Ingress
    Canary Service
    Canary Ingress

    View full-size slide

  29. @hossambarakat_

    View full-size slide

  30. @hossambarakat_
    • What metrics to measure and its frequency
    • What values are considered successful or failed
    • Continuously run in the background.
    Analysis

    View full-size slide

  31. @hossambarakat_
    Metric Provider Integration

    View full-size slide

  32. @hossambarakat_

    View full-size slide

  33. @hossambarakat_
    Questions?

    View full-size slide

  34. Thanks
    Hossam Barakat
    @hossambarakat_
    www.hossambarakat.net

    View full-size slide