Fix path for packages in package.json used for Docker image #16141
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.
Description
Due to a recent change in PNPM (pnpm/pnpm#5472) the paths to the tarball of the packages in the
package.json
file generated by thedocker/pack.js
script are no longer relative but absolute and therefore dependent on the executing system (in this case the GitHub runner).This resulted in the tarballs not being found within the Docker image build process because the paths were invalid inside the Docker context.
With the fix provided in this pull request, the release process is going to work again (refs: https://github.com/directus/directus/releases/tag/v9.19.1 & #16083 (comment)).
The fix is backwards-compatible with older PNPM versions.
I've tested it in a forked repository (https://github.com/paescuj/directus/actions/runs/3312870014).
Also included revert of revert of #16083 馃槃
Type of Change
Requirements Checklist
If adding a new feature: