k8s

package
v1.801.462 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 5, 2026 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package k8s is the Kubernetes coordinates, declared once: the GroupVersionResources for our own CRs and the upstream objects we read.

These are VALUES, not per-subsystem opinions: "the operator App CR" is one fact, and it was previously declared three times (apps/platform appsGVR, apps/deploy appsCRGVR, apps/platform appsGVR) under two different names. Three copies of a constant do not disagree until one of them is edited — and the whole point of the App/Service kind migration is that this coordinate CHANGES. When it does, a subsystem still holding a private copy silently reads the wrong resource and its board goes quietly empty, which is exactly the failure paas already shipped once.

One declaration, one name, every consumer. Adding a coordinate here is how a new subsystem addresses the cluster; declaring a private copy is the bug this package exists to prevent.

Index

Constants

This section is empty.

Variables

View Source
var Apps = schema.GroupVersionResource{Group: "hanzo.ai", Version: "v1", Resource: "apps"}

Apps is the operator's App CR (hanzo.ai/v1) — the ONE workload kind the fleet runs on. `Service` is the v0.3.0 alias it replaced; the fleet holds zero of them, so there is deliberately no ServicesGVR here to scan as well.

View Source
var CDAppProjects = schema.GroupVersionResource{Group: "apps.hanzo.ai", Version: "v1alpha1", Resource: "appprojects"}

CDAppProjects is Hanzo CD's AppProject CR (apps.hanzo.ai/v1alpha1) — the policy envelope a CD Application is admitted under: which repos it may pull from, which destinations it may write to, which resource kinds it may create. A different question from CDApplications: an Application is ONE tracked git source, a project is the boundary a whole set of them may act within.

Same group as every other CD kind. Nothing has ever served argoproj.io here — a GVR naming that group comes back "the server doesn't have a resource type", which a caller treating any error as "CD is not installed" reads as absence.

View Source
var CDApplications = schema.GroupVersionResource{Group: "apps.hanzo.ai", Version: "v1alpha1", Resource: "applications"}

CDApplications is Hanzo CD's Application CR (apps.hanzo.ai/v1alpha1) — the GitOps plane's own record of a tracked git source: the revision it last applied, its sync verdict, and its deploy history. A different fact from Apps: an App is ONE workload's desired state, a CD Application is the git→cluster pipeline that WRITES those Apps, so "the App CR declares vX" and "CD has applied commit abc" answer different questions and neither implies the other.

View Source
var Deployments = schema.GroupVersionResource{Group: "apps", Version: "v1", Resource: "deployments"}

Deployments is the live Deployment behind each App — the source of the RUNNING image tag, since the App CR's status does not surface it.

View Source
var Namespaces = schema.GroupVersionResource{Version: "v1", Resource: "namespaces"}

Namespaces backs scan-set discovery: asking which namespaces exist is how the fleet is found, rather than hardcoding a list that goes stale on the next tenant.

View Source
var Volumes = schema.GroupVersionResource{Version: "v1", Resource: "persistentvolumeclaims"}

Volumes is the PersistentVolumeClaim an app declares storage against. A claim is a DIFFERENT lifetime from the workload that mounts it: the App CR is desired state and can be deleted and recreated freely, while the claim holds the only copy of the tenant's data. Nothing here deletes one.

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL