Skip to content

openshift/cluster-update-console-plugin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

208 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cluster Update Console Plugin

An OpenShift Console dynamic plugin that provides an AI-driven cluster update experience. It integrates with OpenShift Lightspeed proposals (via the agentic.openshift.io API) to assess upgrade readiness, show OLM operator compatibility, and let users approve or reject AI-generated update plans.

Features

  • Update Plan — Shows the active AI-generated update proposal with risk assessment, readiness checks, OLM operator compatibility, API deprecation checks, and approve/deny actions.
  • Active Update Plans — Lists all non-terminal Lightspeed proposals.
  • Update History — Shows the ClusterVersion update history.
  • Graceful Degradation — Works without the Lightspeed Proposal CRD installed. The Update History tab is always functional; AI features show a warning banner when unavailable.

Prerequisites

Development

Local development

In one terminal:

yarn install
yarn start

In another terminal:

oc login  # log into your OpenShift cluster
yarn start-console

Navigate to http://localhost:9000/administration/cluster-update.

The plugin dev server runs on port 9001 with CORS enabled. The console bridge runs on port 9000.

Testing with mock data

Without the Lightspeed agentic operator installed, Proposals have no analysis data. To test with mock data:

  1. Verify CVO-created Proposals exist:

    oc -n openshift-lightspeed get proposals.agentic.openshift.io
  2. Get the Proposal UID:

    oc -n openshift-lightspeed get proposals.agentic.openshift.io -o custom-columns=NAME:.metadata.name,UID:.metadata.uid
  3. Update mock-analysis-result.yaml with the correct Proposal name and UID in ownerReferences, then apply:

    oc apply -f mock-analysis-result.yaml
  4. Patch the Proposal status to reference the AnalysisResult (see comments in mock-analysis-result.yaml for the full command).

  5. Patch the AnalysisResult status subresource with options data (the status field is a subresource, so oc apply won't set it — use oc patch --subresource status).

Code quality

yarn lint    # eslint + prettier + stylelint (with --fix)
yarn test    # Jest unit tests

Styling rules

The .stylelintrc.yaml enforces strict rules to prevent breaking console:

  • No hex colors — use PatternFly CSS variables
  • No naked element selectors (table, div, etc.)
  • No .pf- or .co- prefixed classes
  • Prefix all custom classes with cluster-update-plugin__

Building and deploying

Build the image

docker build -t quay.io/my-repository/cluster-update-console-plugin:latest .
# For Apple Silicon: add --platform=linux/amd64

Deploy via Helm

helm upgrade -i cluster-update-console-plugin charts/openshift-console-plugin \
  -n cluster-update-console-plugin \
  --create-namespace \
  --set plugin.image=quay.io/my-repository/cluster-update-console-plugin:latest

i18n

The i18n namespace is plugin__cluster-update-console-plugin. Use the useTranslation hook:

import { I18N_NAMESPACE } from '../utils/constants';
const { t } = useTranslation(I18N_NAMESPACE);

For labels in console-extensions.json:

"name": "%plugin__cluster-update-console-plugin~Cluster Update%"

Run yarn i18n after adding or changing messages to update locale files.

References

About

In-cluster web console plugin for cluster version and update management

Resources

License

Security policy

Stars

2 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors