Skip to content

Replace gcr.io container image references with ghcr.io#4428

Open
aravindtga wants to merge 2 commits intokptdev:mainfrom
Nordix:replace-missing-gcr-to-ghcr
Open

Replace gcr.io container image references with ghcr.io#4428
aravindtga wants to merge 2 commits intokptdev:mainfrom
Nordix:replace-missing-gcr-to-ghcr

Conversation

@aravindtga
Copy link
Contributor

@aravindtga aravindtga commented Mar 10, 2026

Description

Migrates container image references from gcr.io to ghcr.io across documentation, test data, and test files.

The following references are preserved:

  • k8s.gcr.io (Kubernetes system images)
  • gcr.io/cloud-builders/docker (Cloud Build)
  • gcr.io/google.com/cloudsdktool/cloud-sdk (Google Cloud SDK)

Additionally, this PR adds wasm function image support and fixes Go 1.21+ wasm compatibility:

  • Wasm images: Built and pushed wasm variants of KRM functions (set-labels, set-namespace) to ghcr.io/kptdev/krm-functions-catalog/wasm/ (Manual)
  • Wasm e2e tests: Added basicpipeline-wasm render test and wasm-function eval test using the new ghcr.io wasm images
  • Go 1.21+ wasm fix: Renamed the wasm import module from "go" to "gojs" in the nodejs JS glue code (internal/fnruntime/jsglue.go) to match the breaking change introduced in Go 1.21.
  • CI: Set KPT_FN_WASM_RUNTIME=nodejs in the CI workflow since the wasmexec library used by the wasmtime runtime is not yet updated for Go 1.21+

@netlify
Copy link

netlify bot commented Mar 10, 2026

Deploy Preview for kptdocs ready!

Name Link
🔨 Latest commit dc7c8a2
🔍 Latest deploy log https://app.netlify.com/projects/kptdocs/deploys/69b308d511e6b300088b4fed
😎 Deploy Preview https://deploy-preview-4428--kptdocs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@dosubot dosubot bot added the lgtm label Mar 10, 2026
@aravindtga aravindtga force-pushed the replace-missing-gcr-to-ghcr branch from 0e1924f to e731212 Compare March 10, 2026 14:23
Signed-off-by: aravind.est <aravindhan.a@est.tech>
@aravindtga aravindtga force-pushed the replace-missing-gcr-to-ghcr branch 2 times, most recently from dd2ee6d to 620ebff Compare March 12, 2026 17:46
@aravindtga aravindtga marked this pull request as ready for review March 12, 2026 18:22
Copilot AI review requested due to automatic review settings March 12, 2026 18:22
@dosubot dosubot bot added size:L This PR changes 100-499 lines, ignoring generated files. go Pull requests that update Go code labels Mar 12, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Migrates container image references from gcr.io to ghcr.io across docs and test fixtures, and updates WASM-related e2e coverage and runtime compatibility for Go 1.21+.

Changes:

  • Replace gcr.io image references with ghcr.io in documentation, unit tests, and YAML testdata.
  • Add/adjust WASM e2e testdata to use ghcr.io/kptdev/krm-functions-catalog/wasm/* images and set the WASM runtime to nodejs where expected.
  • Update the embedded NodeJS WASM glue code to use Go’s newer WASM import module name (gojs) and set KPT_FN_WASM_RUNTIME=nodejs in CI.

Reviewed changes

Copilot reviewed 32 out of 34 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
thirdparty/kyaml/runfn/test/testdata/java/java-deployment.resource.yaml Update example deployment image reference to ghcr.io.
thirdparty/kyaml/runfn/runfn_test.go Update test image references to ghcr.io.
thirdparty/cmdconfig/commands/cmdtree/cmdtree_test.go Update embedded YAML image references to ghcr.io.
thirdparty/cmdconfig/commands/cmdsource/cmdsource_test.go Update embedded YAML/JSON image references to ghcr.io.
thirdparty/cmdconfig/commands/cmdsink/cmdsink_test.go Update embedded YAML image references to ghcr.io.
internal/testutil/testdata/updateMergeConflict/mysql/mysql-statefulset.resource.yaml Update test fixture image references to ghcr.io.
internal/testutil/testdata/updateMergeConflict/java/java-deployment.resource.yaml Update test fixture image reference to ghcr.io.
internal/testutil/testdata/datasetmerged/mysql/mysql-statefulset.resource.yaml Update test fixture image references to ghcr.io.
internal/testutil/testdata/datasetmerged/java/java-deployment.resource.yaml Update test fixture image reference to ghcr.io.
internal/testutil/testdata/dataset6/mysql/mysql-statefulset.resource.yaml Update test fixture image references to ghcr.io.
internal/testutil/testdata/dataset6/java/java-deployment.resource.yaml Update test fixture image reference to ghcr.io.
internal/testutil/testdata/dataset5/mysql/mysql-statefulset.resource.yaml Update test fixture image references to ghcr.io.
internal/testutil/testdata/dataset5/java/java-deployment.resource.yaml Update test fixture image reference to ghcr.io.
internal/testutil/testdata/dataset4/mysql/mysql-statefulset.resource.yaml Update test fixture image references to ghcr.io.
internal/testutil/testdata/dataset4/java/java-deployment.resource.yaml Update test fixture image reference to ghcr.io.
internal/testutil/testdata/dataset3/mysql/mysql-statefulset.resource.yaml Update test fixture image references to ghcr.io.
internal/testutil/testdata/dataset3/java/java-deployment.resource.yaml Update test fixture image reference to ghcr.io.
internal/testutil/testdata/dataset2/mysql/mysql-statefulset.resource.yaml Update test fixture image references to ghcr.io.
internal/testutil/testdata/dataset2/java/java-deployment.resource.yaml Update test fixture image reference to ghcr.io.
internal/testutil/testdata/dataset1/mysql/mysql-statefulset.resource.yaml Update test fixture image references to ghcr.io.
internal/testutil/testdata/dataset1/java/java-deployment.resource.yaml Update test fixture image reference to ghcr.io.
internal/fnruntime/jsglue.go Adjust embedded WASM JS glue import module name for Go 1.21+.
internal/docs/generated/wasmdocs/docs.go Update WASM push/pull examples to ghcr.io.
internal/docs/generated/fndocs/docs.go Update fn examples to ghcr.io and refresh generated render docs content.
e2e/testdata/fn-render/basicpipeline-wasm/Kptfile Point WASM pipeline to new ghcr.io/.../wasm/* images.
e2e/testdata/fn-render/basicpipeline-wasm/.expected/setup.sh Set expected WASM runtime to nodejs.
e2e/testdata/fn-render/basicpipeline-wasm/.expected/diff.patch Update expected render diff output for the WASM pipeline case.
e2e/testdata/fn-eval/wasm-function/.expected/config.yaml Update eval test to use the new ghcr.io WASM image.
documentation/content/en/reference/cli/fn/source/_index.md Update docs example image reference to ghcr.io.
documentation/content/en/reference/cli/fn/sink/_index.md Update docs example image reference to ghcr.io.
documentation/content/en/reference/cli/fn/eval/_index.md Update docs examples to ghcr.io.
documentation/content/en/reference/cli/alpha/wasm/push/_index.md Update docs example image reference to ghcr.io.
documentation/content/en/reference/cli/alpha/wasm/pull/_index.md Update docs example image reference to ghcr.io.
.github/workflows/go.yml Set KPT_FN_WASM_RUNTIME=nodejs in the Linux CI test job.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

New WASM images published.
It's a manual process now.
Fix Go 1.21+ wasm compatibility by renaming the import module from go to gojs in the nodejs JS glue code. The wasmexec library used by the wasmtime runtime has the same issue but requires
a separate upstream fix.

Signed-off-by: aravind.est <aravindhan.a@est.tech>
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 32 out of 34 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

go Pull requests that update Go code lgtm size:L This PR changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants