Skip to content

feat: annotate generated resources with l8k version - #170

Merged
almaslennikov merged 1 commit into
mainfrom
feat/launch-kit-version-annotations
Aug 14, 2026
Merged

feat: annotate generated resources with l8k version#170
almaslennikov merged 1 commit into
mainfrom
feat/launch-kit-version-annotations

Conversation

@almaslennikov

@almaslennikov almaslennikov commented Aug 13, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • annotate every Kubernetes object generated by Launch Kit with nvidia.kubernetes-launch-kit.version: <release-version>, including multi-document manifests and custom workloads
  • reuse the existing version reported by l8k version for the annotation value
  • apply the same annotation to standard resources rendered during Network Operator Helm install and upgrade, preserving existing annotations
  • document the generated-manifest and Helm behavior in the README

Helm hooks and chart CRDs are excluded because Helm does not pass them through post-renderers.

Testing

  • go test ./... -count=1
  • go test -race -count=1 ./pkg/networkoperatorplugin ./pkg/app ./pkg/cmd ./pkg/target/host
  • golangci-lint v2.11.0 run ./...
  • make build VERSION=v9.8.7 and verify l8k version
  • generate an SR-IOV deployment bundle and verify every YAML resource document carries v9.8.7 while values.yaml remains unchanged

@greptile-apps

greptile-apps Bot commented Aug 13, 2026

Copy link
Copy Markdown

Greptile Summary

The PR propagates centralized Launch Kit build metadata through generation and deployment so generated Kubernetes objects and Helm-rendered resources receive a version annotation while preserving existing annotations.

  • Adds multi-document YAML annotation handling for generated manifests.
  • Adds a Helm post-renderer for Network Operator chart resources.
  • Threads the release version through CLI, Host target, application, and plugin boundaries.
  • Adds annotation and Helm behavior tests plus user-facing documentation.

Confidence Score: 4/5

The PR is not yet safe to merge because tagged release images still embed the fallback version and consequently stamp generated and deployed resources with incorrect release metadata.

The release-image workflow does not pass the Git tag into the Docker build, so make build uses v0.1.0; the new propagation paths then consistently expose that incorrect value through l8k version and Kubernetes resource annotations.

Files Needing Attention: Dockerfile, Makefile, and .github/workflows/image-push-release.yml

Important Files Changed

Filename Overview
pkg/networkoperatorplugin/annotations.go Adds YAML-stream processing that preserves existing annotations and sets the Launch Kit version on each Kubernetes resource document.
pkg/networkoperatorplugin/templates.go Applies version annotations to generated resource manifests while excluding the non-resource Helm values file.
pkg/networkoperatorplugin/helm.go Installs the annotation post-renderer on Helm install and upgrade operations.
pkg/networkoperatorplugin/deploy.go Threads the Launch Kit version into the Helm deployment phase.
pkg/target/host/deploy.go Passes standalone deploy requests’ build version into Network Operator deployment options.
pkg/cmd/generate.go Seeds generation options with the binary’s linker-injected version.
pkg/cmd/deploy.go Seeds standalone deployment requests with the binary’s linker-injected version.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart LR
  V[Build-time cmd.Version] --> C[CLI command options]
  C --> H[Host target requests]
  H --> P[Network Operator plugin]
  P --> G[Generated manifest annotator]
  P --> R[Helm post-renderer]
  G --> Y[Version-annotated YAML resources]
  R --> K[Version-annotated chart resources]
Loading

Reviews (2): Last reviewed commit: "feat: annotate generated resources with ..." | Re-trigger Greptile

Comment thread Dockerfile Outdated
Signed-off-by: Alexander Maslennikov <amaslennikov@nvidia.com>
@almaslennikov
almaslennikov force-pushed the feat/launch-kit-version-annotations branch from 20cf4ac to 9a561d6 Compare August 13, 2026 15:49
@almaslennikov
almaslennikov merged commit 5aecd12 into main Aug 14, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant