Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .claude-plugin/marketplace.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@
},
"metadata": {
"description": "Orchestrator skill for RHDH plugin development - onboard, update, and maintain plugins in the Extensions Catalog",
"version": "0.3.1"
"version": "0.3.2"
},
"plugins": [
{
"name": "rhdh",
"source": "./",
"description": "Skills for RHDH plugin lifecycle management",
"version": "0.3.1",
"version": "0.3.2",
"strict": true
}
]
Expand Down
2 changes: 1 addition & 1 deletion .claude-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "rhdh",
"description": "All-in-one toolkit for Red Hat Developer Hub (RHDH). Covers plugin development, overlay management, environment setup, version compatibility, CI/CD, and RHDH ecosystem navigation.",
"version": "0.3.1",
"version": "0.3.2",
"author": {
"name": "RHDH Store Manager"
},
Expand Down
13 changes: 13 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,19 @@ Update Konflux task digests and apply `MIGRATION.md` pipeline changes in [rhdh-p
npx skills add redhat-developer/rhdh-skill --skill konflux-tekton-updates
```

### Platform Lifecycle

Check version support status for platforms and integrations used by RHDH.

- **[lifecycle](./skills/lifecycle/SKILL.md)** — Check version lifecycle and support status for OCP, AKS, EKS, GKE, RHDH releases, RHBK, Quay, PostgreSQL, and any Red Hat product via the Product Life Cycles API.

### CI / Prow

Manage Prow CI job configurations and trigger nightly E2E tests.

- **[prow](./skills/prow/SKILL.md)** — Manage Prow CI job configurations for RHDH in the openshift/release repository. List, generate, add, and remove OCP test entries and cluster pools. List K8s platform test entries (AKS, EKS, GKE). Analyze coverage gaps. Commission new release branches and decommission end-of-life ones.
- **[prow-trigger-nightly](./skills/prow-trigger-nightly/SKILL.md)** — Trigger RHDH nightly ProwJobs on demand via the OpenShift CI Gangway REST API. Supports both rhdh and rhdh-plugin-export-overlays repos with Gangway overrides for catalog index image, chart version, and Playwright version.

### Local Testing

Test plugins in a local RHDH instance before deploying.
Expand Down
6 changes: 6 additions & 0 deletions docs/adr/0002-stdlib-only-python-clis.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,9 @@ Both CLIs (`rhdh` and `rhdh-local`) use only Python 3.9+ standard library — ze
- **`uv`** as the dev tool runner (`uv run pytest`) — not shipped with the CLIs, but used for development and testing

New scripts and CLI commands in this project should follow these same patterns.

## Exceptions

Prow skill scripts (under `skills/prow/scripts/`) use `ruamel.yaml` for round-trip YAML processing — preserving comments, key ordering, and quoting style that the stdlib `yaml` module cannot handle. These scripts declare the dependency via PEP 723 inline script metadata (`# /// script` blocks), and `uv run --script` auto-installs it in an ephemeral virtual environment. No user-facing install step is required.

The stdlib-only rule still applies to the main CLIs and any script not run via `uv run --script`.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "rhdh-skill"
version = "0.3.1"
version = "0.3.2"
description = "Claude Code skill for RHDH plugin development"
readme = "README.md"
license = "Apache-2.0"
Expand Down
64 changes: 54 additions & 10 deletions skills/prow-trigger-nightly/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ description: >-
Trigger RHDH nightly ProwJobs via the OpenShift CI Gangway REST API.

Supports two repositories:

- **rhdh** — the main RHDH application (`periodic-ci-redhat-developer-rhdh-*-nightly`)
- **rhdh-plugin-export-overlays** — plugin export overlays (`periodic-ci-redhat-developer-rhdh-plugin-export-overlays-*-nightly`)

Expand Down Expand Up @@ -56,6 +57,7 @@ Then ask the user to describe which job and branch they want in natural language
Map the user's description to the matching full job name from the fetched list. If no branch is mentioned, default to `main`:

**RHDH repo jobs:**

- "ocp helm" / "openshift helm" -> `e2e-ocp-helm-nightly` (not upgrade, not versioned)
- "operator" / "ocp operator" -> `e2e-ocp-operator-nightly` (not auth-providers)
- "helm upgrade" / "upgrade test" -> `e2e-ocp-helm-upgrade-nightly`
Expand All @@ -72,6 +74,7 @@ Map the user's description to the matching full job name from the fetched list.
- Multiple: "all AKS jobs", "all Operator jobs on main" -> offer to trigger them in sequence

**Overlay repo jobs:**

- "overlay nightly" / "overlay helm" / "overlays nightly" -> `periodic-ci-redhat-developer-rhdh-plugin-export-overlays-main-e2e-ocp-helm-nightly`

### Shared Cluster Constraint (GKE / OSD-GCP only)
Expand All @@ -80,21 +83,34 @@ GKE and OSD-GCP each share a single cluster — never run two jobs on the same p

## Step 2: Options

**Important:** Overlay repo jobs only support fork overrides (`--org`, `--repo`, `--branch`). Image overrides (`--image-registry`, `--image-repo`, `--tag`) and `--send-alerts` are NOT supported — the script will error if these are passed for an overlay job. If the user doesn't need fork overrides, skip this step and go directly to Step 3.
### Overlay repo jobs

Overlay jobs support fork overrides (`--org`, `--repo`, `--branch`), catalog index override (`--catalog-index-image`), and Playwright version override (`--playwright-version`).

Image overrides (`--image-registry`, `--image-repo`, `--tag`), `--chart-version`, and `--send-alerts` are NOT supported — the script will error if these are passed for an overlay job.

If the user doesn't need any overrides, skip this step and go directly to Step 3.

For RHDH repo jobs, present all options together. The user picks by number — multiple selections allowed (e.g. "2, 5"):
### RHDH repo jobs

Present all options together. The user picks by number — multiple selections allowed (e.g. "2, 5"):

**Image override:**

1. **Default image** — no image flags, use whatever the job is configured with
2. **Custom tag only** — override just the tag, keep default registry and repo
3. **Custom repo + tag** — override image repository and tag, keep default registry (`quay.io`)
4. **Fully custom image** — override registry, repo, and tag

**Catalog & chart override:**
5. **Catalog index image** — override the plugin catalog index image (`--catalog-index-image`)
6. **Chart version** — override the Helm chart version (`--chart-version`)

**Additional options:**
5. **Fork override** — run against a fork instead of `redhat-developer/rhdh`
6. **Send Slack alerts** — notify via `--send-alerts`
7. **Fork override** — run against a fork instead of `redhat-developer/rhdh`
8. **Send Slack alerts** — notify via `--send-alerts`

Constraint: `--image-repo` requires `--tag`, but `--tag` works on its own.
Constraint: `--image-repo` requires `--tag`, but `--tag` works on its own. `--playwright-version` is overlay-only and will error for RHDH jobs.

### Follow-up based on selections

Expand All @@ -111,11 +127,17 @@ uv run scripts/trigger_nightly_job.py --list-tags
Use `--image-repo <REPO>` to query a different image repository (default: `rhdh/rhdh-hub-rhel9`). Present the numbered results with a final option to enter a custom tag (e.g. `next`, `latest`). For option 3, also ask for the image repository.

**If 4 selected (non-quay registry)** — ask for all three values (tag fetching not available):

- Registry (e.g. `brew.registry.redhat.io`)
- Image repo (e.g. `rhdh/rhdh-hub-rhel9`)
- Tag (e.g. `1.9`)

**If 5 selected** — ask for:
**If 5 selected** — ask for catalog index image (e.g. `quay.io/rhdh/plugin-catalog-index:1.9-60` for RC, `registry.access.redhat.com/rhdh/plugin-catalog-index:1.9.4` for GA).

**If 6 selected** — ask for chart version (e.g. `1.9-227-CI`).

**If 7 selected** — ask for:

- GitHub org (`--org`): e.g. `my-github-user`
- Repo name (`--repo`): e.g. `rhdh`
- Branch (`--branch`): e.g. `my-feature-branch`
Expand All @@ -130,6 +152,9 @@ uv run scripts/trigger_nightly_job.py \
[--image-registry <REGISTRY>] \
[--image-repo <REPO>] \
[--tag <TAG>] \
[--catalog-index-image <IMAGE>] \
[--chart-version <VERSION>] \
[--playwright-version <VERSION>] \
[--org <ORG>] \
[--repo <REPO>] \
[--branch <BRANCH>] \
Expand All @@ -142,14 +167,33 @@ uv run scripts/trigger_nightly_job.py \

After execution, show the API response. If a job URL or ID is returned, display it prominently. On error, help diagnose (common issues: expired token, invalid job name).

### RC Verification Example

```bash
uv run scripts/trigger_nightly_job.py \
--job periodic-ci-redhat-developer-rhdh-main-e2e-ocp-helm-nightly \
--image-repo rhdh/rhdh-hub-rhel9 --tag 1.9-227 \
--catalog-index-image quay.io/rhdh/plugin-catalog-index:1.9 \
--chart-version 1.9-227-CI
```

### GA Verification Example

```bash
uv run scripts/trigger_nightly_job.py \
--job periodic-ci-redhat-developer-rhdh-main-e2e-ocp-helm-nightly \
--image-registry registry.redhat.io --image-repo rhdh/rhdh-hub-rhel9 --tag 1.9.4 \
--catalog-index-image registry.access.redhat.com/rhdh/plugin-catalog-index:1.9.4
```

## Reference

- Script flags: `-j/--job`, `-l/--list`, `-T/--list-tags`, `--tag-filter`, `-I/--image-registry`, `-q/--image-repo`, `-t/--tag`, `-o/--org`, `-r/--repo`, `-b/--branch`, `-S/--send-alerts`, `-n/--dry-run`, `--json`
- Script flags: `-j/--job`, `-l/--list`, `-T/--list-tags`, `--tag-filter`, `-I/--image-registry`, `-q/--image-repo`, `-t/--tag`, `--catalog-index-image`, `--chart-version`, `--playwright-version`, `-o/--org`, `-r/--repo`, `-b/--branch`, `-S/--send-alerts`, `-n/--dry-run`, `--json`
- Dedicated kubeconfig at `~/.config/openshift-ci/kubeconfig` — won't interfere with your current cluster context
- If auth is needed, the script opens a browser for SSO login
- RHDH jobs list: https://prow.ci.openshift.org/configured-jobs/redhat-developer/rhdh
- Overlay jobs list: https://prow.ci.openshift.org/configured-jobs/redhat-developer/rhdh-plugin-export-overlays
- Image tags: https://quay.io/repository/rhdh/rhdh-hub-rhel9?tab=tags
- RHDH jobs list: <https://prow.ci.openshift.org/configured-jobs/redhat-developer/rhdh>
- Overlay jobs list: <https://prow.ci.openshift.org/configured-jobs/redhat-developer/rhdh-plugin-export-overlays>
- Image tags: <https://quay.io/repository/rhdh/rhdh-hub-rhel9?tab=tags>

## Related Skills

Expand Down
90 changes: 63 additions & 27 deletions skills/prow-trigger-nightly/scripts/trigger_nightly_job.py
Original file line number Diff line number Diff line change
Expand Up @@ -353,15 +353,17 @@ def build_payload(args: argparse.Namespace) -> dict:
is_overlay = args.job.startswith(OVERLAY_JOB_PREFIX)

if is_overlay:
# Overlay jobs support fork overrides only (org, repo, branch).
# Image overrides and alerts are not supported.
# Overlay jobs support fork overrides, catalog index, and playwright version.
# Image overrides, chart version, and alerts are not supported.
unsupported: list[str] = []
if args.image_repo:
unsupported.append("--image-repo")
if args.image_registry:
unsupported.append("--image-registry")
if args.tag:
unsupported.append("--tag")
if args.chart_version:
unsupported.append("--chart-version")
if args.send_alerts:
unsupported.append("--send-alerts")
if unsupported:
Expand All @@ -377,7 +379,16 @@ def build_payload(args: argparse.Namespace) -> dict:
envs["MULTISTAGE_PARAM_OVERRIDE_GITHUB_REPOSITORY_NAME"] = args.repo
if args.branch:
envs["MULTISTAGE_PARAM_OVERRIDE_RELEASE_BRANCH_NAME"] = args.branch
if args.catalog_index_image:
envs["MULTISTAGE_PARAM_OVERRIDE_CATALOG_INDEX_IMAGE"] = args.catalog_index_image
if args.playwright_version:
envs["MULTISTAGE_PARAM_OVERRIDE_PLAYWRIGHT_VERSION"] = args.playwright_version
else:
# RHDH repo jobs do not support playwright version.
if args.playwright_version:
log_error("--playwright-version is only supported for overlay jobs.")
sys.exit(1)

# RHDH repo jobs support full overrides.
if args.image_repo:
envs["MULTISTAGE_PARAM_OVERRIDE_IMAGE_REPO"] = args.image_repo
Expand All @@ -391,6 +402,10 @@ def build_payload(args: argparse.Namespace) -> dict:
envs["MULTISTAGE_PARAM_OVERRIDE_GITHUB_REPOSITORY_NAME"] = args.repo
if args.branch:
envs["MULTISTAGE_PARAM_OVERRIDE_RELEASE_BRANCH_NAME"] = args.branch
if args.catalog_index_image:
envs["MULTISTAGE_PARAM_OVERRIDE_CATALOG_INDEX_IMAGE"] = args.catalog_index_image
if args.chart_version:
envs["MULTISTAGE_PARAM_OVERRIDE_CHART_VERSION"] = args.chart_version

skip_alert = "false" if args.send_alerts else "true"
envs["MULTISTAGE_PARAM_OVERRIDE_SKIP_SEND_ALERT"] = skip_alert
Expand Down Expand Up @@ -531,56 +546,77 @@ def parse_args(argv: list[str] | None = None) -> argparse.Namespace:
help="Filter tags by version prefix (e.g. '1.10'). Used with --list-tags.",
)

overrides = parser.add_argument_group("RHDH job overrides (not supported for overlay jobs)")
overrides.add_argument(
shared = parser.add_argument_group("Shared overrides (both rhdh and overlay jobs)")
shared.add_argument(
"-o",
"--org",
dest="org",
default="",
help="Override the GitHub org (default: redhat-developer).",
)
shared.add_argument(
"-r",
"--repo",
dest="repo",
default="",
help="Override the GitHub repo name (default: rhdh).",
)
shared.add_argument(
"-b",
"--branch",
dest="branch",
default="",
help="Override the branch name.",
)
shared.add_argument(
"--catalog-index-image",
dest="catalog_index_image",
default="",
help="Override the catalog index image (e.g. quay.io/rhdh/plugin-catalog-index:1.9-60).",
)

rhdh_only = parser.add_argument_group("RHDH-only overrides (not supported for overlay jobs)")
rhdh_only.add_argument(
"-I",
"--image-registry",
dest="image_registry",
default="",
help="Override the image registry (default: quay.io).",
)
overrides.add_argument(
rhdh_only.add_argument(
"-q",
"--image-repo",
dest="image_repo",
default="",
help="Override the image repository (e.g. rhdh/rhdh-hub-rhel9). Requires --tag.",
)
overrides.add_argument(
rhdh_only.add_argument(
"-t",
"--tag",
dest="tag",
default="",
help="Override the image tag (e.g. 1.9-123).",
)
overrides.add_argument(
"-o",
"--org",
dest="org",
default="",
help="Override the GitHub org (default: redhat-developer).",
)
overrides.add_argument(
"-r",
"--repo",
dest="repo",
default="",
help="Override the GitHub repo name (default: rhdh).",
)
overrides.add_argument(
"-b",
"--branch",
dest="branch",
rhdh_only.add_argument(
"--chart-version",
dest="chart_version",
default="",
help="Override the branch name.",
help="Override the Helm chart version (e.g. 1.9-227-CI).",
)

parser.add_argument(
rhdh_only.add_argument(
"-S",
"--send-alerts",
action="store_true",
help="Send Slack alerts (default: alerts are skipped).",
)

overlay_only = parser.add_argument_group("Overlay-only overrides (not supported for rhdh jobs)")
overlay_only.add_argument(
"--playwright-version",
dest="playwright_version",
default="",
help="Override the Playwright version (overlay jobs only).",
)
parser.add_argument(
"-n",
"--dry-run",
Expand Down
7 changes: 4 additions & 3 deletions skills/prow/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ description: >-
Manage Prow CI job configurations for RHDH in the openshift/release
repository. List, generate, add, and remove OCP test entries and cluster
pools. List K8s platform test entries (AKS, EKS, GKE). Analyze OCP
version coverage gaps. Decommission end-of-life release branches. Use
when working with RHDH CI config, Prow jobs, cluster pools, or
openshift/release CI management.
version coverage gaps. Commission new release branches and decommission
end-of-life ones. Use when working with RHDH CI config, Prow jobs,
cluster pools, or openshift/release CI management.
---
# RHDH Prow CI Management

Expand All @@ -32,6 +32,7 @@ What CI management task do you need?
| "cluster pool", "ClusterPool", "Hive pool" | `workflows/ocp-pools.md` |
| "coverage", "gap analysis", "what OCP versions are missing" | `workflows/ocp-coverage.md` |
| "AKS test", "EKS test", "GKE test", "K8s platform jobs" | `workflows/k8s-jobs.md` |
| "commission", "new release branch", "create release branch CI", "onboard release", "add release branch" | `workflows/commission-release.md` |
| "decommission", "EOL release", "remove release branch", "clean up old release" | `workflows/decommission-release.md` |

After reading the workflow, follow it exactly.
Expand Down
Loading
Loading