Skip to content

Onboard Konflux Kite to Kargo with paired image promotion - #1213

Merged
openshift-merge-bot[bot] merged 1 commit into
redhat-appstudio:mainfrom
flacatus:codex/onboard-konflux-kite
Nov 10, 2026
Merged

openshift-merge-bot[bot] merged 1 commit into
redhat-appstudio:mainfrom
flacatus:codex/onboard-konflux-kite

Conversation

@flacatus

Copy link
Copy Markdown
Contributor

What

Onboard infra-deployments/components/konflux-kite as the separate Kargo project kargo-konflux-kite, with a Warehouse and Rings 0–4 using the shared publication, CI, merge and Argo readiness tasks.

  • Subscribe to the immutable shared-base Git revision and the published kite-prod / kite-init images. Require matching full source SHA tags before editing either image, so the API and database migration versions advance together.
  • Enable automatic promotion and PR merging, with no soak times. Ring 0 requires Prow conformance; Rings 1–4 use approximately 24 hours of single-architecture Kanary verification.
  • Grant the existing konflux-ui group promoter access. Mirror Kite maintainers as component reviewers/documentation approvers while retaining platform approval for executable workflows, policies and RBAC.
  • Add the project to shard access and promotion-cleaner configuration.

Environments affected: Kargo internal-production configuration governing Kite development, staging and production rings.

Why

Kite has a ring deployment layout but no dedicated Kargo project. The API and database migration images build separately; independently selecting their newest tags without checking equality can deploy an incompatible pair. Ring-local database, credential and certificate settings must remain separate from the promoted shared base.

Validation

  • Inventory checked at infra-deployments commit 3910309c017d73ee54ab95294ed1a6d622dc6af7, including rendered staging/production ApplicationSets, cluster assignments, Kanary workload inventory, component owners and the konflux-ui maintainer binding.
  • Confirmed both public image repositories publish full SHA tags and inspected their build definitions and image metadata. Their available tag sets differ, validating the need for the pair guard.
  • Preparation simulation rendered all 15 configured overlays with the same selected API and migration SHA; ring-local settings and files outside the shared snapshots/image overrides remained unchanged.
  • 88 expression checks cover matched/mismatched/missing Freight, invalid destinations and image repositories, unexpected layouts, and withholding prepared: yes after any required step fails.
  • Verified all 11 validation schema files match the official Kargo v1.12.4 Git blobs (1b6a368d3dcfc64de36e487a9e5c410b430a03c8).
  • Kargo v1.12.4 CRD and step schema validation, task-reference resolution, ring source chain, cluster counts, promoter permissions and additive platform RBAC checks pass.
  • Kustomize builds pass for the new project, all projects, shard RBAC, promotion cleaner and all four root environment overlays. YAML lint and git diff --check pass.
  • Independent code review found no actionable correctness or security issues in the new project/integrations.
  • Local validation only; live credentials, CI, Argo and Kanary execution were not available. The project starts with CI-only Ring 0 and staging Ring 1 before production. No separate deployed staging PR is claimed.

Risk Assessment

Risk Level: Medium.

Automatic rollouts include a database migration init container. Matching image tags prevent a known version mismatch, but do not prove migration compatibility or image provenance. Kanary checks platform build health rather than Kite-specific functionality. Already-applied database migrations are not undone by reverting this onboarding.

Independent image discovery can temporarily produce mismatched Freight; preparation fails closed until a matching release pair is available. Images are promoted by SHA tag with explicit name, newName and newTag, not digest.

Ring 1 Argo readiness covers all four configured Kite clusters; Kanary covers the two that have workloads configured. lightwell-dev is excluded by the staging ApplicationSet. Per the existing rollout requirement, kflux-lw-p01 is excluded from both verification lists even though its Ring 2 overlay receives the shared update; this coverage gap and its inventory evidence are documented. The other six Ring 2 targets, both Ring 3 targets, and Ring 4 are verified.

Team access does not include project-admin, Secret reads, or extra workflow mutation permissions. Platform owners approve executable configuration. Existing projects and shared task implementations are unchanged; this PR has no dependency on the separate changelog PR #1211.

Rollback: Revert this PR to remove the onboarding configuration. The Project retains its namespace/history. Revert any already-merged deployment PRs separately and assess database migration rollback before changing Kite versions.

Add the dedicated project, ring promotion flow, cluster verification and
promoter access for konflux-ui while preserving platform approval of policy.

Assisted-by: OpenAI Codex
Signed-off-by: flacatus <flacatus@redhat.com>
@openshift-ci

openshift-ci Bot commented Nov 10, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: flacatus

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@qodo-for-redhat-appstudio

Copy link
Copy Markdown

PR Summary by Qodo

Onboard Konflux Kite to Kargo with paired image promotion

✨ Enhancement ⚙️ Configuration changes 📝 Documentation 🕐 40+ Minutes

Grey Divider

AI Description

• Add a dedicated Kite Warehouse and five automatically promoted deployment rings.
• Require matching API and migration image source SHAs while preserving ring-local configuration.
• Apply shared CI and deployment gates, Kanary verification, and scoped project access.
Diagram

graph TD
  W["Kite Warehouse"] --> G{"Matching SHAs?"} --> R0["Ring 0 CI"] --> R1["Ring 1 staging"] --> R2["Ring 2 production"] --> R3["Ring 3 production"] --> R4["Ring 4 production"]
Loading
High-Level Assessment

The following are alternative approaches to this PR:

1. Publish an atomic paired-release descriptor
  • ➕ Prevents mismatched API and migration versions from entering release selection.
  • ➕ Makes the build pipeline the source of truth for a complete Kite release.
  • ➖ Requires upstream publication and Kargo discovery changes.
  • ➖ Adds coordination beyond this project's existing Warehouse pattern.

Recommendation: Use the project-local SHA guard for this onboarding: the two repositories are discovered independently, and the guard fails before deployment edits or PR publication. An upstream paired-release descriptor would be worth considering if mismatched discovery routinely stalls promotion.

Files changed (30) +1327 / -0

Enhancement (7) +873 / -0
promotiontask.yamlGuard and prepare paired Kite images +100/-0

Guard and prepare paired Kite images

• Rejects missing, malformed, or mismatched image SHAs and unexpected target layouts before editing the checkout. Copies only the immutable shared base, sets both image tags, and reports success only after every required step succeeds.

components/kargo/internal-production/projects/kargo-konflux-kite/components/konflux-kite/promotiontask.yaml

ring-0-stage.yamlConfigure development promotion and Prow gate +124/-0

Configure development promotion and Prow gate

• Sources Freight directly from the Warehouse and uses shared publish, CI, and merge tasks. Requires the Prow conformance check without adding Argo or Kanary verification.

components/kargo/internal-production/projects/kargo-konflux-kite/components/konflux-kite/stages/ring-0-stage.yaml

ring-1-stage.yamlConfigure staging promotion and verification +155/-0

Configure staging promotion and verification

• Sources Ring 0 Freight, verifies Argo readiness on four staging clusters, and runs approximately 24 hours of single-architecture Kanary checks on two clusters.

components/kargo/internal-production/projects/kargo-konflux-kite/components/konflux-kite/stages/ring-1-stage.yaml

ring-2-stage.yamlConfigure first production-ring gates +155/-0

Configure first production-ring gates

• Sources Ring 1 Freight and applies shared promotion tasks, Argo readiness, and single-architecture Kanary checks to six production clusters.

components/kargo/internal-production/projects/kargo-konflux-kite/components/konflux-kite/stages/ring-2-stage.yaml

ring-3-stage.yamlConfigure second production-ring gates +155/-0

Configure second production-ring gates

• Sources Ring 2 Freight and verifies deployment readiness and Kanary signals on two production clusters.

components/kargo/internal-production/projects/kargo-konflux-kite/components/konflux-kite/stages/ring-3-stage.yaml

ring-4-stage.yamlConfigure final production-ring gates +155/-0

Configure final production-ring gates

• Sources Ring 3 Freight and verifies Argo deployment readiness and Kanary signals on kflux-prd-rh02.

components/kargo/internal-production/projects/kargo-konflux-kite/components/konflux-kite/stages/ring-4-stage.yaml

warehouse.yamlDiscover the shared base and two Kite images +29/-0

Discover the shared base and two Kite images

• Automatically creates Freight from relevant infra-deployments commits and full-SHA tags in the API and migration image repositories. Image discovery is independent; the preparation task enforces pairing.

components/kargo/internal-production/projects/kargo-konflux-kite/components/konflux-kite/warehouse.yaml

Documentation (1) +92 / -0
README.mdDocument Kite release and rollout policy +92/-0

Document Kite release and rollout policy

• Explains paired image selection, ring-specific verification, cluster coverage exceptions, access boundaries, validation, and rollback limitations.

components/kargo/internal-production/projects/kargo-konflux-kite/README.md

Other (22) +362 / -0
config.yamlRegister Kite for promotion cleanup +1/-0

Register Kite for promotion cleanup

• Adds the Kite project to the promotion cleaner's project list.

components/kargo/internal-production/platform/promotion-cleaner/config.yaml

rolebindings.yamlGrant cleaner access to the Kite namespace +30/-0

Grant cleaner access to the Kite namespace

• Binds the cleaner service account to its Kubernetes cleanup role and the Kargo promoter role in the new namespace.

components/kargo/internal-production/platform/promotion-cleaner/rolebindings.yaml

project-rbac.yamlAllow staging shard access to Kite +15/-0

Allow staging shard access to Kite

• Grants the staging shard service account project access in the Kite namespace.

components/kargo/internal-production/platform/shard-rbac/project-rbac.yaml

OWNERSKeep project-level approval with platform owners +21/-0

Keep project-level approval with platform owners

• Defines project approvers and reviewers and disables inherited parent ownership.

components/kargo/internal-production/projects/kargo-konflux-kite/OWNERS

kustomization.yamlAssemble core Kite project resources +8/-0

Assemble core Kite project resources

• Includes the namespace, Project, automatic promotion policies, and RBAC resources.

components/kargo/internal-production/projects/kargo-konflux-kite/base/kustomization.yaml

namespace.yamlCreate the Kite Kargo namespace +7/-0

Create the Kite Kargo namespace

• Declares and labels the namespace as a Kargo project namespace.

components/kargo/internal-production/projects/kargo-konflux-kite/base/namespace.yaml

project-config.yamlEnable automatic promotion across all five rings +17/-0

Enable automatic promotion across all five rings

• Adds auto-promotion policies for Kite Rings 0–4.

components/kargo/internal-production/projects/kargo-konflux-kite/base/project-config.yaml

project.yamlDeclare the Kite Kargo project +7/-0

Declare the Kite Kargo project

• Creates the Project and requests namespace retention when the Project is removed.

components/kargo/internal-production/projects/kargo-konflux-kite/base/project.yaml

analysis-template-rbac.yamlPermit Argo CD to manage analysis templates +33/-0

Permit Argo CD to manage analysis templates

• Grants the Argo CD application controller namespaced access to AnalysisTemplate resources.

components/kargo/internal-production/projects/kargo-konflux-kite/base/rbac/analysis-template-rbac.yaml

argocd-app-reader.yamlProvision Argo CD application-reader credentials +28/-0

Provision Argo CD application-reader credentials

• Creates a service account and token Secret and binds the account to the existing application-reader ClusterRole.

components/kargo/internal-production/projects/kargo-konflux-kite/base/rbac/argocd-app-reader.yaml

kargo-konflux-kite-promoter-rb.yamlGrant Kite maintainers promoter access +15/-0

Grant Kite maintainers promoter access

• Binds the project promoter service account and the konflux-ui group to the built-in Kargo promoter Role.

components/kargo/internal-production/projects/kargo-konflux-kite/base/rbac/kargo-konflux-kite-promoter-rb.yaml

kargo-konflux-kite-promoter-sa.yamlCreate the Kite promoter service account +9/-0

Create the Kite promoter service account

• Adds the project-scoped promoter account with a konflux-ui group claim.

components/kargo/internal-production/projects/kargo-konflux-kite/base/rbac/kargo-konflux-kite-promoter-sa.yaml

kargo-manager-promoter-extras-rb.yamlBind manager-only promotion controls +15/-0

Bind manager-only promotion controls

• Gives kargo-manager the additional namespaced permissions for Freight approval and abort operations.

components/kargo/internal-production/projects/kargo-konflux-kite/base/rbac/kargo-manager-promoter-extras-rb.yaml

kargo-manager-promoter-rb.yamlAllow Kargo manager to promote Kite +14/-0

Allow Kargo manager to promote Kite

• Binds kargo-manager to the project's promoter Role for promotion creation and updates.

components/kargo/internal-production/projects/kargo-konflux-kite/base/rbac/kargo-manager-promoter-rb.yaml

kargo-promoter-extras-role.yamlDefine restricted promotion-control permissions +29/-0

Define restricted promotion-control permissions

• Creates a Role for patching Freight status, Promotions, and Stages without granting project administration.

components/kargo/internal-production/projects/kargo-konflux-kite/base/rbac/kargo-promoter-extras-role.yaml

kustomization.yamlAssemble Kite project RBAC +12/-0

Assemble Kite project RBAC

• Includes the project administration, application-reader, analysis-template, promoter, and manager bindings.

components/kargo/internal-production/projects/kargo-konflux-kite/base/rbac/kustomization.yaml

rbac.yamlDefine project administrators and viewers +49/-0

Define project administrators and viewers

• Grants platform groups Kargo resource administration and Secret read access while binding authenticated OAuth users to the viewer role.

components/kargo/internal-production/projects/kargo-konflux-kite/base/rbac/rbac.yaml

OWNERSAdd Kite maintainer review ownership +19/-0

Add Kite maintainer review ownership

• Lists Kite maintainers as component reviewers and documentation approvers without granting approval over executable policy.

components/kargo/internal-production/projects/kargo-konflux-kite/components/konflux-kite/OWNERS

kustomization.yamlAssemble Kite promotion resources +7/-0

Assemble Kite promotion resources

• Includes the Warehouse, paired-image preparation task, and five stages.

components/kargo/internal-production/projects/kargo-konflux-kite/components/konflux-kite/kustomization.yaml

kustomization.yamlInclude Kite's five rollout stages +9/-0

Include Kite's five rollout stages

• Collects the Ring 0–4 Stage manifests into the component build.

components/kargo/internal-production/projects/kargo-konflux-kite/components/konflux-kite/stages/kustomization.yaml

kustomization.yamlWire Kite into shared Kargo workflows +16/-0

Wire Kite into shared Kargo workflows

• Builds the project in its namespace with shared promotion tasks and verification templates.

components/kargo/internal-production/projects/kargo-konflux-kite/kustomization.yaml

kustomization.yamlInclude Kite in the project aggregate +1/-0

Include Kite in the project aggregate

• Adds the Kite project to the internal-production Kargo project build.

components/kargo/internal-production/projects/kustomization.yaml

@qodo-for-redhat-appstudio

Copy link
Copy Markdown

Code Review by Qodo

🐞 Bugs (0) 📘 Rule violations (0) 📎 Requirement gaps (0)

Great, no issues found!

Qodo reviewed your code and found no material issues that require review

Qodo Logo

@p8r-the-gr8

Copy link
Copy Markdown
Contributor

/lgtm

@openshift-ci openshift-ci Bot added the lgtm label Nov 10, 2026
@openshift-merge-bot
openshift-merge-bot Bot merged commit a9afae7 into redhat-appstudio:main Nov 10, 2026
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants