keel

by Helm

Helm chartv0.7.2App 0.12.0

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

About this chart

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 ***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 and Quay 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 and standard webhook notifications, more info here

Installing

Docker image polling, Kubernetes provider and Helm provider support are set by default, then Kubernetes deployments can be upgraded when new Docker image is available:

$ helm upgrade --install keel --namespace keel keel/

Setting up Helm release to be automatically updated by Keel

Add the following to your app's values.yaml file and do helm upgrade ...:

keel:
  # keel policy (all/major/minor/patch/force)
  policy: all
  # trigger type, defaults to events such as pubsub, webhooks
  trigger: poll
  # polling schedule
  pollSchedule: "@every 3m"
  # images to track and update
  images:
    - repository: image.repository # it must be the same names as your app's values
      tag: image.tag # it must be the same names as your app's values

The same can be applied with --set flag without using values.yaml file:

$ helm upgrade --install whd webhookdemo --namespace keel --reuse-values \
  --set keel.policy="all",keel.trigger="poll",keel.pollSchedule="@every 3m" \
  --set keel.images[0].repository="image.repository" \
  --set keel.images[0].tag="image.tag"

You can read in more details about supported policies, triggers and etc in the User Guide.

Also you should check the Webhooh demo app and it's chart to have more clear idea how to set automatic updates.

Uninstalling the Chart

To uninstall/delete the keel deployment:

$ helm delete --purge keel

The command removes all the Kubernetes components associated with the chart and deletes the release.

Configuration

The following table lists has the main configurable parameters (polling, triggers, notifications, service) of the Keel chart and they apply to both Kubernetes and Helm providers:

ParameterDescriptionDefault
polling.enabledDocker registries pollingtrue
helmProvider.enabledEnable/disable Helm providertrue
gcr.enabledEnable/disable GCR Registryfalse
gcr.projectIDGCP Project ID GCR belongs to
gcr.pubsub.enabledEnable/disable GCP Pub/Sub triggerfalse
ecr.enabledEnable/disable AWS ECR Registryfalse
ecr.accessKeyIdAWS_ACCESS_KEY_ID for ECR Registry
ecr.secretAccessKeyAWS_SECRET_ACCESS_KEY for ECR Registry
ecr.regionAWS_REGION for ECR Registry
webhook.enabledEnable/disable Webhook Notificationfalse
webhook.endpointRemote webhook endpoint
slack.enabledEnable/disable Slack Notificationfalse
slack.tokenSlack token
slack.channelSlack channel
slack.approvalsChannelSlack channel for approvals
service.enableEnable/disable Keel servicefalse
service.typeKeel service typeLoadBalancer
service.externalPortKeel service port9300
webhookRelay.enabledEnable/disable WebhookRelay integrationfalse
webhookRelay.keyWebhookRelay key
webhookRelay.secretWebhookRelay secret
webhookRelay.bucketWebhookRelay bucket
rbac.enabledEnable/disable RBAC installationfalse
hipchat.enabledEnable/disable hipchat integrationfalse
hipchat.tokenHipchat token
hipchat.channelHipchat channel
hipchat.approvalsChannelHipchat channel for approvals
hipchat.botNameName of the Hipchat bot
hipchat.userNameHipchat username in Jabber format
hipchat.passwordHipchat password for approvals user
googleApplicationCredentialsGCP Service account key configurable
notificationLevelKeel notification levelinfo

Specify each parameter using the --set key=value[,key=value] argument to helm install.

Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart. For example,

$ helm install --name keel --namespace keel -f values.yaml keel/

Tip: You can use the default values.yaml

Deploy keel with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has keel on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartkeel is pinned at v0.7.2 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply