-
Notifications
You must be signed in to change notification settings - Fork 97
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Migrate to GHCR #6478
Migrate to GHCR #6478
Conversation
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
Test Results3 022 tests +4 3 010 ✔️ +1 2m 50s ⏱️ -9s Results for commit 44762b7. ± Comparison against base commit d0f928e. This pull request removes 2 and adds 6 tests. Note that renamed tests count towards both.
This pull request skips 3 tests.
♻️ This comment has been updated with latest results. |
.github/workflows/build.yaml
Outdated
uses: docker/setup-buildx-action@v2 | ||
registry: ghcr.io | ||
username: ${{ env.GHCR_ACTOR }} | ||
password: ${{ secrets.GH_RAD_CI_BOT_PAT }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of CI_BOT can we use the normal actions token instead?
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
@@ -73,7 +73,7 @@ func (drc *devRecipeClient) GetDevRecipes(ctx context.Context) (map[string]map[s | |||
recipes := map[string]map[string]corerp.RecipePropertiesClassification{} | |||
|
|||
// if repository has the correct path it should look like: <registryPath>/recipes/<category>/<type>:<tag> | |||
// Ex: radius.azurecr.io/recipes/local-dev/rediscaches:0.20 | |||
// Ex: ghcr.io/radius-project/recipes/local-dev/rediscaches:0.20 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Our prod registry is ghcr.io/radius-project
and dev is ghcr.io/radius-project/dev
, right? This logic checks everything under the DevRecipeRegistry
(which is defined above) and goes through all the repos underneath that registry. If under ghcr.io/radius-project/dev
we have recipes, they might get installed in the env too. The logic here should be very well tested with the new registry.
Another thing is that the logic here takes radius-rp
as the starting point (see line 78). Was that repo also moved to ghcr? Were everything from azurecr moved to ghcr?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yetkin and I updated this logic. should be good now
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
@@ -69,5 +65,5 @@ do | |||
|
|||
echo "Publishing $RECIPE to $PUBLISH_REF" | |||
echo "- $PUBLISH_REF" >> $GITHUB_STEP_SUMMARY | |||
$BICEP_EXECUTABLE publish $RECIPE --target "br:$PUBLISH_REF" | |||
rad bicep publish --file $RECIPE --target "br:$PUBLISH_REF" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
using the bicep executable directly did not seem to work with GHCR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep this known behavior. The Bicep executable and our fork can only talk to ACR. We had to bring in the ability to talk to any OCI registry to the rad CLI directly.
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
pull_request: | ||
branches: | ||
- main | ||
# pull_request: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I disabled this on PR because it takes > an hour. It will still run as scheduled.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This only runs the there are changes to the actual workflow file. Please create an issue to re-enable this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.
For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/. |
Radius functional test overview
Click here to see the list of tools in the current test run
Test Status⌛ Building Radius and pushing container images for functional tests... |
* Replace `radius.azurecr.io` with `ghcr.io/radius-project` * Replace `radiusdev.azurecr.io` with `ghcr.io/radius-project/dev` * Add step to publish latest rad CLI to `ghcr.io` * Refactoring `Build and Test` GH workflow to improve clarity * Removing ACR publishes and pulls from GH workflows * Removing instances of azurecr.io and ACR from our docs <!-- Please select **one** of the following options that describes your change and delete the others. Clearly identifying the type of change you are making will help us review your PR faster, and is used in authoring release notes. If you are making a bug fix or functionality change to Radius and do not have an associated issue link please create one now. --> - This pull request adds or changes features of Radius and has an approved issue (issue link required). <!-- Please update the following to link the associated issue. This is required for some kinds of changes (see above). --> Fixes: #6362 Fixes: #6295 <!-- GitHub Copilot for docs will auto-generate a summary of the PR --> <!-- copilot:all --> 🔄🛠️🧪 <!-- 1. 🔄 - This emoji represents the change of registry from ACR to GHCR, which is a significant change that affects how the artifacts are stored and accessed. 2. 🛠️ - This emoji represents the update of the tools and commands used to build and push the artifacts, such as ORAS CLI, Docker Buildx, and Helm Registry plugin, which are different from the previous ones and may require some adjustments or documentation. 3. 🧪 - This emoji represents the update of the functional-test workflow, which is related to testing the quality and functionality of the artifacts and the bicep recipes. --> This pull request updates the GitHub workflows to use GHCR as the new registry for radius artifacts. It changes the build.yaml workflow to use new tools and commands for building and pushing the rad CLI, the radius images, and the radius helm chart to GHCR. It also changes the functional-test.yaml workflow to use GHCR for bicep recipes instead of ACR. > _We're sailing on the GitHub seas, with rad and radius tools_ > _We've changed our registry, to GHCR from ACR_ > _So heave away, me hearties, heave away with `oras` and `buildx`_ > _And don't forget to push the helm chart, with the registry plugin_ * Remove `GOPROXY` and `DOCKER_REGISTRY` environment variables and add `ORAS_VERSION` and `IMAGE_SRC` environment variables to support ORAS CLI for pushing rad CLI binaries to GHCR ([link](https://github.com/radius-project/radius/pull/6478/files?diff=unified&w=0#diff-d0777657fa3fd81d23aaf7273e58aee453b04e67882517900c56daeef9b3e4c1L39-R42)) * Rename `build` job to `build-and-push-cli` and add `build-and-push-images` job to build and push radius container images to GHCR using Docker Buildx ([link](https://github.com/radius-project/radius/pull/6478/files?diff=unified&w=0#diff-d0777657fa3fd81d23aaf7273e58aee453b04e67882517900c56daeef9b3e4c1L57-R59)) * Remove `images` job and add `publish_images` job to build and push rad CLI binaries to GHCR using ORAS CLI for different platforms and architectures ([link](https://github.com/radius-project/radius/pull/6478/files?diff=unified&w=0#diff-d0777657fa3fd81d23aaf7273e58aee453b04e67882517900c56daeef9b3e4c1L207-R226)) * Rename `helm` job to `build-and-push-helm-chart` and use Helm Registry plugin to push radius helm chart to GHCR ([link](https://github.com/radius-project/radius/pull/6478/files?diff=unified&w=0#diff-d0777657fa3fd81d23aaf7273e58aee453b04e67882517900c56daeef9b3e4c1L312-R277)) * Rename `publish_release` job to `publish-release` and change `needs` condition to depend on `build-and-push-cli` job ([link](https://github.com/radius-project/radius/pull/6478/files?diff=unified&w=0#diff-d0777657fa3fd81d23aaf7273e58aee453b04e67882517900c56daeef9b3e4c1L353-R319)) * Remove `publish` job and update `delete_artifacts` job to depend on `build-and-push-cli` job ([link](https://github.com/radius-project/radius/pull/6478/files?diff=unified&w=0#diff-d0777657fa3fd81d23aaf7273e58aee453b04e67882517900c56daeef9b3e4c1L391-R359)) * Change `BICEP_RECIPE_REGISTRY` environment variable to use GHCR instead of ACR for bicep recipes in `.github/workflows/functional-test.yaml` ([link](https://github.com/radius-project/radius/pull/6478/files?diff=unified&w=0#diff-c79f364a9293abaaa8595776b74674e24bec6287834e63ab8aa7aec6a42f0dbcL56-R56)) * Add comment to indicate that `az acr login` command needs to be changed to use GHCR in `.github/workflows/functional-test.yaml` ([link](https://github.com/radius-project/radius/pull/6478/files?diff=unified&w=0#diff-c79f364a9293abaaa8595776b74674e24bec6287834e63ab8aa7aec6a42f0dbcR81)) * Remove `az acr login` command from `.github/workflows/functional-test.yaml` as it is no longer needed ([link](https://github.com/radius-project/radius/pull/6478/files?diff=unified&w=0#diff-c79f364a9293abaaa8595776b74674e24bec6287834e63ab8aa7aec6a42f0dbcL486-L488)) --------- Co-authored-by: ytimocin <[email protected]> (cherry picked from commit a197131)
Description
radius.azurecr.io
withghcr.io/radius-project
radiusdev.azurecr.io
withghcr.io/radius-project/dev
ghcr.io
Build and Test
GH workflow to improve clarityType of change
Fixes: #6362
Fixes: #6295
Auto-generated summary
🤖 Generated by Copilot at 787b494
Summary
🔄🛠️🧪
This pull request updates the GitHub workflows to use GHCR as the new registry for radius artifacts. It changes the build.yaml workflow to use new tools and commands for building and pushing the rad CLI, the radius images, and the radius helm chart to GHCR. It also changes the functional-test.yaml workflow to use GHCR for bicep recipes instead of ACR.
Walkthrough
GOPROXY
andDOCKER_REGISTRY
environment variables and addORAS_VERSION
andIMAGE_SRC
environment variables to support ORAS CLI for pushing rad CLI binaries to GHCR (link)build
job tobuild-and-push-cli
and addbuild-and-push-images
job to build and push radius container images to GHCR using Docker Buildx (link)images
job and addpublish_images
job to build and push rad CLI binaries to GHCR using ORAS CLI for different platforms and architectures (link)helm
job tobuild-and-push-helm-chart
and use Helm Registry plugin to push radius helm chart to GHCR (link)publish_release
job topublish-release
and changeneeds
condition to depend onbuild-and-push-cli
job (link)publish
job and updatedelete_artifacts
job to depend onbuild-and-push-cli
job (link)BICEP_RECIPE_REGISTRY
environment variable to use GHCR instead of ACR for bicep recipes in.github/workflows/functional-test.yaml
(link)az acr login
command needs to be changed to use GHCR in.github/workflows/functional-test.yaml
(link)az acr login
command from.github/workflows/functional-test.yaml
as it is no longer needed (link)