Skip to content
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

Cache restore issue with symbolic links #11

Closed
wass3r opened this issue Apr 14, 2020 · 1 comment
Closed

Cache restore issue with symbolic links #11

wass3r opened this issue Apr 14, 2020 · 1 comment
Labels
bug Indicates a bug

Comments

@wass3r
Copy link
Collaborator

wass3r commented Apr 14, 2020

for applications using npm or yarn that want to cache their dependencies (ie. node_modules folder), the restored cache resolves symlinks incorrectly.

example restored cache items:

$ ls -la node_modules/.bin
total 16
drwxr-xr-x 2 root root 4096 Apr 14 19:33 .
drwxr-xr-x 313 root root 12288 Apr 14 19:33 ..
lrwxrwxrwx 1 root root 23 Apr 14 19:33 acorn -> node_modules/.bin/acorn
lrwxrwxrwx 1 root root 22 Apr 14 19:33 atob -> node_modules/.bin/atob
lrwxrwxrwx 1 root root 23 Apr 14 19:33 errno -> node_modules/.bin/errno
lrwxrwxrwx 1 root root 38 Apr 14 19:33 import-local-fixture -> node_modules/.bin/import-local-fixture
lrwxrwxrwx 1 root root 23 Apr 14 19:33 json5 -> node_modules/.bin/json5
lrwxrwxrwx 1 root root 30 Apr 14 19:33 miller-rabin -> node_modules/.bin/miller-rabin
lrwxrwxrwx 1 root root 24 Apr 14 19:33 mkdirp -> node_modules/.bin/mkdirp
lrwxrwxrwx 1 root root 24 Apr 14 19:33 rimraf -> node_modules/.bin/rimraf
lrwxrwxrwx 1 root root 24 Apr 14 19:33 semver -> node_modules/.bin/semver
lrwxrwxrwx 1 root root 24 Apr 14 19:33 sha.js -> node_modules/.bin/sha.js
lrwxrwxrwx 1 root root 24 Apr 14 19:33 terser -> node_modules/.bin/terser
lrwxrwxrwx 1 root root 25 Apr 14 19:33 webpack -> node_modules/.bin/webpack
lrwxrwxrwx 1 root root 29 Apr 14 19:33 webpack-cli -> node_modules/.bin/webpack-cli
lrwxrwxrwx 1 root root 23 Apr 14 19:33 which -> node_modules/.bin/which

expected output should be:

$ ls -la node_modules/.bin
total 16
drwxr-xr-x 2 root root 4096 Apr 14 19:34 .
drwxr-xr-x 313 root root 12288 Apr 14 19:34 ..
lrwxrwxrwx 1 root root 18 Apr 14 19:34 acorn -> ../acorn/bin/acorn
lrwxrwxrwx 1 root root 19 Apr 14 19:34 atob -> ../atob/bin/atob.js
lrwxrwxrwx 1 root root 15 Apr 14 19:34 errno -> ../errno/cli.js
lrwxrwxrwx 1 root root 31 Apr 14 19:34 import-local-fixture -> ../import-local/fixtures/cli.js
lrwxrwxrwx 1 root root 19 Apr 14 19:34 json5 -> ../json5/lib/cli.js
lrwxrwxrwx 1 root root 32 Apr 14 19:34 miller-rabin -> ../miller-rabin/bin/miller-rabin
lrwxrwxrwx 1 root root 20 Apr 14 19:34 mkdirp -> ../mkdirp/bin/cmd.js
lrwxrwxrwx 1 root root 16 Apr 14 19:34 rimraf -> ../rimraf/bin.js
lrwxrwxrwx 1 root root 20 Apr 14 19:34 semver -> ../semver/bin/semver
lrwxrwxrwx 1 root root 16 Apr 14 19:34 sha.js -> ../sha.js/bin.js
lrwxrwxrwx 1 root root 20 Apr 14 19:34 terser -> ../terser/bin/terser
lrwxrwxrwx 1 root root 25 Apr 14 19:34 webpack -> ../webpack/bin/webpack.js
lrwxrwxrwx 1 root root 25 Apr 14 19:34 webpack-cli -> ../webpack-cli/bin/cli.js
lrwxrwxrwx 1 root root 18 Apr 14 19:34 which -> ../which/bin/which

potentially related to this: mholt/archiver#202

@jbrockopp
Copy link
Contributor

Hello 👋

The Vela admins have decided to condense all existing issues into a single repo found @ go-vela/community.

For a direct link to your counterpart issue in that repo, you can find it linked in the history of this issue.

If you have any questions, please feel free to direct them to the community repo.

Thanks for your input and feedback!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Indicates a bug
Projects
None yet
Development

No branches or pull requests

2 participants