Skip to content

Commit b0da320

Browse files
committed
Clear stale resource-metadata hubs before generating catalog
image-packer embeds the resource-metadata hubs, but the reloader used by kmodules.xyz/resource-metadata shadows the embedded copies with /tmp/hub/<hub> when those directories exist. A stale or empty leftover there makes image-packer load nothing and emit a broken catalog, so remove /tmp/hub before running. The underlying reloader flaw is fixed upstream in gomodules.xyz/x (gomodules/x#71); this guards catalog generation until that lands and re-vendors. Signed-off-by: Tamal Saha <tamal@appscode.com>
1 parent 9840d9d commit b0da320

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

hack/scripts/update-catalog.sh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,14 @@
1616

1717
set -eou pipefail
1818

19+
# image-packer embeds the resource-metadata hubs (resourceeditors,
20+
# resourcedescriptors, clusterprofiles), but the reloader used by
21+
# kmodules.xyz/resource-metadata shadows the embedded copies with
22+
# /tmp/hub/<hub> when those directories exist. A stale or empty leftover
23+
# there makes image-packer load nothing and emit a broken catalog, so
24+
# remove them before running.
25+
rm -rf /tmp/hub
26+
1927
image-packer list --root-dir=charts --output-dir=catalog
2028

2129
image-packer list-feature-charts --root-dir=charts --output-dir=catalog

0 commit comments

Comments
 (0)