Disable safe.directory git checks in the container image #22188
+3
−19
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
git config --system --add safe.directory $PWD
is required in our setup when using containers in the CI. However, setting it once per job is not enough - it is not persisted between steps.It coused problems during 3.6.3-RC1 release - https://github.com/scala/scala3/actions/runs/12253895253/job/34194840440#step:15:25
It also leads to swallowed exceptions when republishing SDK https://github.com/scala/scala3/actions/runs/12253895253/job/34194840440#step:15:25
It is also a blocker for tests in LTS fork, in safe directory should be set to $PWD in every fork - https://github.com/scala/scala3-lts/pull/23/files
We can disabled the safe.directory checks globally in the published docker image.
Tested in a fork repository: https://github.com/WojciechMazur/dotty/pull/2/checks
Before merging requires:
lampepfl:dotty
container image