Fix crane install permissions in GHCR CI - #93
pawelchcki wants to merge 3 commits into
Conversation
Co-authored-by: pawelchcki <pawel.chcki@gmail.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 61759c073f
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| mkdir -p "$crane_bin_dir" | ||
| tar -xzf "$crane_archive" -C "$crane_bin_dir" crane | ||
| export PATH="$crane_bin_dir:$PATH" |
There was a problem hiding this comment.
Move the crane fix to the source template
This file says it is synced from DataDog/dd-repo-tools and must not be edited here. The next campaign sync can replace this local install fix, restore extraction to /usr/local/bin, and break the job again. Apply the fix to the named source template, then sync the generated file.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
@pawelchcki Indeed, it seems we should rather fix https://github.com/DataDog/dd-repo-tools/blob/main/shared/devcontainer/devcontainer-to-ghcr.yml.
This comment has been minimized.
This comment has been minimized.
Co-authored-by: pawelchcki <pawel.chcki@gmail.com>
This reverts commit de0c40d. Co-authored-by: pawelchcki <pawel.chcki@gmail.com>
Summary
The
devcontainer_to_ghcrjob failed while extractingcraneinto/usr/local/bin, which the CI image cannot write. The fix installs it in the job workspace. A temporary PR run verified the archive checksum, extraction, andcrane versionin the actual GitLab CI image. The temporary PR rule has been removed.Changes
craneinto a writable directory underCI_PROJECT_DIRand add it to the job'sPATH.after_script, which runs in a separate shell.Testing
devcontainer_to_ghcrpassed on the temporary PR probe, which exited aftercrane versionand before GHCR authentication or publishing.sh -n.PR by Bits - View session in Datadog
Comment @DataDog to request changes