-
Notifications
You must be signed in to change notification settings - Fork 434
Fix: sed portability and compatibility issue for the bundle commitSha image #2010
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
Conversation
05cfee2 to
f2c20dd
Compare
rahulait
left a comment
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.
LGTM. If additional file creation was an issue, we could have also used yq. For now, this also looks good to me.
That won't be an issue since we have a Linux runner for CI/CD, so a local file won't be created. A local file will only be created if we use Mac-OS, such as during local testing. |
… image Signed-off-by: Shiva Kumar (SW-CLOUD) <[email protected]>
|
/ok-to-test a73f0f0 |
https://github.com/NVIDIA/gpu-operator/actions/runs/20362800010/job/58514956441 : The CI pipeline failed after merging to main: #1898 from NVIDIA/bundlecommitsha : Tag git commit sha with bundle image
https://github.com/NVIDIA/gpu-operator/actions/runs/20364821808/job/58518239572 : Pipeline was reproduced
https://github.com/NVIDIA/gpu-operator/actions/runs/20364821808/job/58518239572: Pipeline passed with the new change
Please refer to the links below for details on the bug and compatibility issues with sed:
sed -i '' -e 's|ghcr.io/nvidia/gpu-operator:[^ "]*|ghcr.io/nvidia/gpu-operator:${{ env.COMMIT_SHORT_SHA }}|g' bundle/manifests/gpu-operator-certified.clusterserviceversion.yaml: This command works only on Mac OS.sed -i'' -e 's|ghcr.io/nvidia/gpu-operator:[^ "]*|ghcr.io/nvidia/gpu-operator:${{ env.COMMIT_SHORT_SHA }}|g' bundle/manifests/gpu-operator-certified.clusterserviceversion.yaml: This works for both MacOS and Linux, creates a backup file with a -e extension on macOSsed -i -e 's|ghcr.io/nvidia/gpu-operator:[^ "]*|ghcr.io/nvidia/gpu-operator:${{ env.COMMIT_SHORT_SHA }}|g' bundle/manifests/gpu-operator-certified.clusterserviceversion.yaml: This works only on Linux, not Mac OS.