Skip to main content
Work in Progress

You are viewing development documentation built from the latest commit on main (last tag v0.2.0-rc.2, source commit 25e1a892). APIs and features are subject to change.

Kure

A GitOps domain model and layout engine, on a thin Kubernetes foundation.

Kure helps platform teams describe a cluster in Go and write it out as plain Kubernetes YAML for GitOps workflows — without Helm templates, runtime controllers, or fragile string-based YAML manipulation.

Get Started View on GitHub

Why Kure?

Building Kubernetes manifests for GitOps can be challenging:

  • YAML templating is error-prone and hard to maintain at scale
  • Helm charts add complexity with their templating language and release lifecycle
  • Raw manifests lead to duplication and inconsistency across clusters

Kure answers this in three layers. A domain model says what a cluster contains. A layout engine turns that into a reconcilable directory tree. Underneath both, a deliberately thin Kubernetes foundation hands you the upstream Go struct with its identity filled in and then gets out of the way — so what you write is checked by the compiler against the real API types, not against kure’s idea of them.

Quick Example

Go code generates plain Kubernetes YAML — no templates, no runtime. The Go block after the imports is the body of Example_siteIndex in pkg/kubernetes, which go test runs and checks against the Example’s own // Output: comment. The YAML tab reproduces that output by hand; it is not generated.

​
import (
    "os"
    "github.com/go-kure/kure/pkg/io"
    "github.com/go-kure/kure/pkg/kubernetes"
)
cm := kubernetes.CreateConfigMap("app-config", "default")
kubernetes.AddConfigMapData(cm, "DATABASE_HOST", "postgres.db.svc")
kubernetes.AddConfigMapData(cm, "DATABASE_PORT", "5432")

if err := io.Marshal(os.Stdout, cm); err != nil {
    panic(err)
}

How It Fits GitOps

Go program  →  Kure builders  →  YAML files  →  Git repository  →  FluxCD reconciles

Kure is a code-time tool. It runs during your build step, outputs plain YAML, and exits. It has no runtime presence in your cluster.

Core Model

Kure organises cluster configuration into a four-level hierarchy:

Cluster  →  Node  →  Bundle  →  Application
LevelPurpose
ClusterRoot; holds GitOps engine config (Flux or ArgoCD)
NodeSubdirectory tree; logical grouping of bundles
BundleDeployment unit; maps to a Flux Kustomization or ArgoCD Application
ApplicationIndividual workload; generates Kubernetes manifests

See Domain Model for the full reference.

What Kure Is and Is Not

Kure is:

  • A domain model and layout engine for GitOps repositories, on a thin Kubernetes foundation
  • A compile-time tool — it runs in your build step, not in your cluster
  • FluxCD-first for GitOps workflow integration
  • Designed to output plain, readable YAML

Kure is not:

  • A runtime controller or operator
  • A wrapper around the Kubernetes API types — the upstream struct is the construction API, and kure adds identity, not a parallel vocabulary
  • A package manager by itself
  • A replacement for every Helm chart use case
  • Required to run inside your target cluster

Kure is the manifest-generation library. Related tooling:

  • go-kure/launcher : An OAM-native package manager built on kure. Optional: you need it only if you want packages rather than a Go program. “kurel” is the launcher’s command-line tool; kure itself ships no CLI. See how the two models relate . Older kure docs that describe a kurel package system describe a prototype that preceded the launcher.

Current Status

  • FluxCD workflow is the primary supported path, with bootstrap generation
  • Argo CD generates Applications; bootstrap is not implemented
  • No stable release yet: the published prereleases and the development docs can both change

The package status page lists every package as supported, limited, consumer-provided, not implemented or proposed.

Start Here

By task: Start takes you from nothing to a cluster on disk, Deliver with Flux turns it into a GitOps repository, and Reference is for looking things up.

Recommended reading order:

  1. Quickstart — generate your first Kubernetes manifest
  2. Domain Model — understand the Cluster → Node → Bundle → Application hierarchy
  3. Builder Contract — what a constructor sets, when a helper exists, how to read the maturity table
  4. Using Kure as a Library — import paths, creating resources, generating YAML
  5. Generating Flux Manifests — end-to-end GitOps layout generation
  6. Examples — practical, runnable examples
  7. API Reference — package documentation

Get Involved

Kure is open source.