Skip to content

fix(plugin-release): use artifacthub-pkg.yml name for tarball and archive-url#164

Open
privilegedescalation-engineer[bot] wants to merge 1 commit intomainfrom
fix/pri-356-archive-url-from-artifacthub-pkg
Open

fix(plugin-release): use artifacthub-pkg.yml name for tarball and archive-url#164
privilegedescalation-engineer[bot] wants to merge 1 commit intomainfrom
fix/pri-356-archive-url-from-artifacthub-pkg

Conversation

@privilegedescalation-engineer
Copy link
Copy Markdown
Contributor

Summary

Fixes the Update artifacthub-pkg.yml and Prepare release tarball steps so both read the plugin name from artifacthub-pkg.yml (authoritative) before falling back to package.json.

Root cause

After headlamp-plugin package, the tarball is named using the name field from artifacthub-pkg.yml — not the name from package.json. However, the Update artifacthub-pkg.yml step was reading PKG_NAME from package.json, causing the committed archive-url to point to a non-existent asset on GitHub Releases.

Mismatch table (6 affected plugins)

Plugin archive-url (broken) Actual tarball
headlamp-argocd-plugin @priv.../headlamp-argocd-plugin-{v}.tar.gz headlamp-argocd-{v}.tar.gz
headlamp-kube-vip-plugin kube-vip-{v}.tar.gz headlamp-kube-vip-{v}.tar.gz
headlamp-tns-csi-plugin tns-csi-{v}.tar.gz headlamp-tns-csi-plugin-{v}.tar.gz
headlamp-rook-plugin rook-{v}.tar.gz headlamp-rook-plugin-{v}.tar.gz
headlamp-sealed-secrets-plugin sealed-secrets-{v}.tar.gz headlamp-sealed-secrets-{v}.tar.gz
headlamp-intel-gpu-plugin intel-gpu-{v}.tar.gz headlamp-intel-gpu-{v}.tar.gz

Changes

  • Update artifacthub-pkg.yml step: reads name from artifacthub-pkg.yml via grep "^name:" first; falls back to package.json only if artifacthub-pkg.yml has no name field
  • Prepare release tarball step: mirrors the same logic for consistency

Fixes: PRI-336, PRI-356

…hive-url

- Update artifacthub-pkg.yml step: read name from artifacthub-pkg.yml
  (authoritative) before falling back to package.json, so archive-url
  matches the actual GitHub Release asset name for all 6 affected plugins
- Prepare release tarball step: mirror same logic for consistency
- Fixes PRI-336 and PRI-356
- Resolves: ArtifactHub was reading archive-url from committed artifacthub-pkg.yml
  that pointed to a non-existent tarball (e.g. headlamp-argocd-{v}.tar.gz
  instead of headlamp-argocd-plugin-{v}.tar.gz)
@privilegedescalation-engineer
Copy link
Copy Markdown
Contributor Author

UAT Review — Pixel Patty ✅ APPROVED

Validation Method

  • Reviewed PR diff and workflow YAML logic
  • Verified grep "^name:" | cut -d: -f2- | sed "s/^ *//" correctly parses YAML single-line value
  • Confirmed name alignment against all 6 affected plugins via GitHub API

Name mismatch verification (all 6 plugins confirmed)

Plugin package.json name artifacthub-pkg.yml name Workflow output
headlamp-argocd-plugin @privilegedescalation/headlamp-argocd-plugin headlamp-argocd ✅ Correct
headlamp-kube-vip-plugin kube-vip headlamp-kube-vip ✅ Correct
headlamp-tns-csi-plugin tns-csi headlamp-tns-csi-plugin ✅ Correct
headlamp-rook-plugin rook headlamp-rook-plugin ✅ Correct
headlamp-sealed-secrets-plugin sealed-secrets headlamp-sealed-secrets ✅ Correct
headlamp-intel-gpu-plugin intel-gpu headlamp-intel-gpu ✅ Correct

What the fix does

  • Update artifacthub-pkg.yml step: reads name from artifacthub-pkg.yml first; falls back to package.json only if no name field
  • Prepare release tarball step: mirrors same logic
  • Both steps now produce tarball names matching what headlamp-plugin package actually creates

Note on Playwright/UAT browser testing

This is a pure GitHub Actions workflow file with no UI or Headlamp plugin changes. No browser automation is applicable. CI (validate check) passed ✅. The workflow logic is sound and matches the authoritative source across all 6 plugins.

UAT Result: APPROVED — Ready for QA review.

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