GithubHelp home page GithubHelp logo

keel-hq / keel Goto Github PK

View Code? Open in Web Editor NEW
2.4K 34.0 280.0 35 MB

Kubernetes Operator to automate Helm, DaemonSet, StatefulSet & Deployment updates

Home Page: https://keel.sh

License: Mozilla Public License 2.0

Makefile 0.32% Go 74.71% Shell 0.44% Dockerfile 0.05% JavaScript 8.45% Vue 14.13% Less 1.51% Mustache 0.14% HTML 0.26%
kubernetes docker automate deployment webhook trigger golang keel semver helm

keel's Introduction

Go Report Docker Pulls Drone Status

Keel - automated Kubernetes deployments for the rest of us

Keel is a tool for automating Kubernetes deployment updates. Keel is stateless, robust and lightweight.

Keel provides several key features:

  • Kubernetes and Helm providers - Keel has direct integrations with Kubernetes and Helm.

  • No CLI/API - tired of f***ctl for everything? Keel doesn't have one. Gets job done through labels, annotations, charts.

  • Semver policies - specify update policy for each deployment/Helm release individually.

  • Automatic Google Container Registry configuration - Keel automatically sets up topic and subscriptions for your deployment images by periodically scanning your environment.

  • Native, DockerHub, Quay and Azure container registry webhooks support - once webhook is received impacted deployments will be identified and updated.

  • Polling - when webhooks and pubsub aren't available - Keel can still be useful by checking Docker Registry for new tags (if current tag is semver) or same tag SHA digest change (ie: latest).

  • Notifications - out of the box Keel has Slack, Hipchat, Mattermost and standard webhook notifications, more info here

Support

Support Keel's development by:

Helm quick start

Prerequisites:

You need to add this Chart repo to Helm:

helm repo add keel https://charts.keel.sh 
helm repo update

Install through Helm (with Helm provider enabled by default):

helm upgrade --install keel --namespace=kube-system keel/keel

If you work mostly with regular Kubernetes manifests, you can install Keel without Helm provider support:

helm upgrade --install keel --namespace=keel keel/keel --set helmProvider.enabled="false" 

To install for Helm v3, set helmProvider.version="v3" (default is "v2"):

helm install keel keel/keel --set helmProvider.version="v3" 

That's it, see Configuration section now.

Quick Start

A step-by-step guide to install Keel on your Kubernetes cluster is viewable on the Keel website:

https://keel.sh/examples/#example-1-push-to-deploy

Configuration

Once Keel is deployed, you only need to specify update policy on your deployment file or Helm chart:

apiVersion: apps/v1
kind: Deployment
metadata: 
  name: wd
  namespace: default
  labels: 
    name: "wd"
  annotations:
    keel.sh/policy: minor # <-- policy name according to https://semver.org/
    keel.sh/trigger: poll # <-- actively query registry, otherwise defaults to webhooks
spec:
  template:
    metadata:
      name: wd
      labels:
        app: wd        
    spec:
      containers:                    
        - image: karolisr/webhook-demo:0.0.8
          imagePullPolicy: Always            
          name: wd
          command: ["/bin/webhook-demo"]
          ports:
            - containerPort: 8090

No additional configuration is required. Enabling continuous delivery for your workloads has never been this easy!

Documentation

Documentation is viewable on the Keel Website:

https://keel.sh/docs/#introduction

Contributing

Before starting to work on some big or medium features - raise an issue here so we can coordinate our efforts.

We use pull requests, so:

  1. Fork this repository
  2. Create a branch on your local copy with a sensible name
  3. Push to your fork and open a pull request

Developing Keel

If you wish to work on Keel itself, you will need Go 1.12+ installed. Make sure you put Keel into correct Gopath and go build (dependency management is done through dep).

To test Keel while developing:

  1. Launch a Kubernetes cluster like Minikube or Docker for Mac with Kubernetes.
  2. Change config to use it: kubectl config use-context docker-for-desktop
  3. Build Keel from cmd/keel directory.
  4. Start Keel with: keel --no-incluster. This will use Kubeconfig from your home.

Running unit tests

Get a test parser (makes output nice):

go get github.com/mfridman/tparse

To run unit tests:

make test

Running e2e tests

Prerequisites:

  • configured kubectl + kubeconfig
  • a running cluster (test suite will create testing namespaces and delete them after tests)
  • Go environment (will compile Keel before running)

Once prerequisites are ready:

make e2e

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.