Git based application deployment patterns for Kubernetes Git ❤ K8s
Shahidh K Muhammed @shahidh_k
Git ● Distributed version control system ● Manage source code ● Any text files can be tracked ● Collaboration
Git - Source of Truth ● Infrastructure as Code ○ Terraform, CloudFormation ● System Configuration as Code ○ Ansible ○ Chef ○ Puppet ● Application Configuration as Code ○ Kubernetes ○ Hasura ● Application Source Code
Declarative tools ❤ Git
Ops ● Configure, build, test, deploy ● CI/CD ● Monitor, fix ● Upgrades ● Rollbacks ● Automation
GitOps ● Ops practices using Git ● Use Git as source of truth ● Drive operations through git repo ● Get version control, history, peer review, and rollback ● Continuous delivery - Automated pipelines ● Webhooks: push to trigger build/test ● PRs & merge branch to deploy
GitOps - Patterns ● CI builds artifacts ● Updates config (in a git repo) ● Trigger rollout (PR merge/commit) ● Observe ● Control
GitOps - Patterns Source: Weave Works
GitOps - Patterns ● Use declarative configuration to define application and services ● All changes go through git review process, none using kubectl ● Use an operator in the cluster to drive observed state to desired state, as declared by the configuration in git ● pre-push hook to create manifests ○ Render templates for correct env ○ Secrets ● pre-receive hook or webhooks to build artifacts and do kubectl set-image ● Power to developer ● Own tooling
Gitkube
Gitkube - Architecture
Demo ● Gitkube ● GitOps at Hasura: ○ Deploying applications ○ Changing subdomain ○ Add a new domain ○ Database migrations
Shahidh K Muhammed @shahidh_k Thanks for listening! Questions? Meetup Koffee With Kubernetes Thursdays 6pm

Git ops: Git based application deployment patterns for Kubernetes

  • 1.
    Git based application deploymentpatterns for Kubernetes Git ❤ K8s
  • 2.
  • 3.
    Git ● Distributed versioncontrol system ● Manage source code ● Any text files can be tracked ● Collaboration
  • 4.
    Git - Sourceof Truth ● Infrastructure as Code ○ Terraform, CloudFormation ● System Configuration as Code ○ Ansible ○ Chef ○ Puppet ● Application Configuration as Code ○ Kubernetes ○ Hasura ● Application Source Code
  • 5.
  • 6.
    Ops ● Configure, build,test, deploy ● CI/CD ● Monitor, fix ● Upgrades ● Rollbacks ● Automation
  • 7.
    GitOps ● Ops practicesusing Git ● Use Git as source of truth ● Drive operations through git repo ● Get version control, history, peer review, and rollback ● Continuous delivery - Automated pipelines ● Webhooks: push to trigger build/test ● PRs & merge branch to deploy
  • 8.
    GitOps - Patterns ●CI builds artifacts ● Updates config (in a git repo) ● Trigger rollout (PR merge/commit) ● Observe ● Control
  • 9.
  • 10.
    GitOps - Patterns ●Use declarative configuration to define application and services ● All changes go through git review process, none using kubectl ● Use an operator in the cluster to drive observed state to desired state, as declared by the configuration in git ● pre-push hook to create manifests ○ Render templates for correct env ○ Secrets ● pre-receive hook or webhooks to build artifacts and do kubectl set-image ● Power to developer ● Own tooling
  • 11.
  • 12.
  • 13.
    Demo ● Gitkube ● GitOpsat Hasura: ○ Deploying applications ○ Changing subdomain ○ Add a new domain ○ Database migrations
  • 14.
    Shahidh K Muhammed @shahidh_k Thanks forlistening! Questions? Meetup Koffee With Kubernetes Thursdays 6pm