Kr8 Save

An opinionated Kubernetes cluster configuration management tool

Project README

kr8

kr8 is a very opinionated tool used for rendering jsonnet manifests for numerous Kubernetes clusters.

It has been designed to work like a simple configuration management framework, allowing operators to specify configuration for components across multiple clusters.

kr8 is a work in progress (currently in Alpha), but is in use at Apptio for managing components of multiple Kubernetes clusters.

For more information about the inspiration and the problem kr8 solves, check out this blog post.

kr8 consists of:

  • kr8 - a Go binary for rendering manifests
  • Task - a third party Go binary for executing tasks
  • Configs - A configuration directory which contains config for clusters and the components installed into those clusters

kr8 is not designed to be a tool to help you install and deploy applications. It's specifically designed to manage and maintain configuration for the cluster level services. For more information, see the components section.

In order to use kr8, you'll need a configuration repository to go with this binary. See the example repo for more information.

Features

  • Generate and customize component configuration for Kubernetes clusters across environments, regions and platforms
  • Opinionated config, flexible deployment. kr8 simply generates manifests for you, you decide how to deploy them
  • Render and override component config from multiple sources, such as Helm, Kustomize and static manifests
  • CI/CD friendly

Concepts & Tools

Component

A component is something you install in your cluster to make it function and work as you expect. Some examples of components might be:

Components are not the applications you want to run in your cluster. Components are generally applications you'd run in your cluster to make those applications function and work as expected.

Clusters

A cluster is a Kubernetes cluster running in a cloud provider, datacenter or elsewhere. You will more than likely have multiple clusters across multiple environments and regions.

Clusters have:

  • Cluster configuration, which can be used as part of the Jsonnet configuration later. This consists of things like the cluster name, type, region etc
  • Components, which you'd like to install in a cluster
  • Component configuration, which is modifications to a component which are specific to a cluster. An example of this might be the path to an SSL certificate for the nginx-ingress controller, which may be different across cloud providers.

Taskfiles

Instead of reinventing the wheel, the kr8 ecosystem makes uses of the Task tool to generate the cluster configuration. The task files generally call kr8 in order to render the manifests for a component. We chose task because it supports yaml and json configuration files, which mean we can continue to leverage jsonnet to write taskfiles where needed.

Jsonnet

All configuration for kr8 is written in Jsonnet. Jsonnet was chosen because it allows us to use code for configuration, while staying as close to JSON as possible.

Building

See the Building documentation.

Contributing

Fork the repo in github and send a merge request!

Caveats

There are currently no tests, and the code is not very DRY.

This was (one of) Apptio's first exercise in Go, and pull requests are very welcome.

Open Source Agenda is not affiliated with "Kr8" Project. README Source: apptio/kr8
Stars
163
Open Issues
10
Last Commit
2 months ago
Repository
License
MIT

Open Source Agenda Badge

Open Source Agenda Rating