Closed jamespedid closed 5 years ago
Figured out that there was a different issue in my pipeline.
If anyone wants to know what my issue was: the symlinks were getting removed when copying sharp files using a nodejs module. I had to dereference the symlinks to make sure the appropriate files were copied over. If you run into this issue, make sure disappearing symlinks is not the cause of your issue.
@jamespedid Do you mind sharing how you solved the issue? I am running into the same issue packing with claudiajs.
@codephobia Hello, not sure if I remember exactly what the issue was, but I believe this is what I did.
I was using nodejs to copy the node modules from one location to another using the fs-extra module. One option in the fs copy command is to 'defererence' the items. I enabled this to true when copying some modules.
await fs.copy('/opt/project/subproject1/node_modules', '/opt/project/output/${jobName}/subproject1/node_modules', { deference: true });
await fs.copy('/opt/project/subproject2/node_modules', '/opt/project/output/${jobName}/subproject1/subproject2/node_modules', { deference: true });
await fs.copy('/opt/project/job/node_modules', '/opt/project/output/${jobName}/subproject1/subproject2/job/node_modules', { deference: true });
The 'tower' of node_modules was used to make resolving dependencies easier, so you can probably ignore that unless you're doing something similar. The deference: true option is I think what you're looking for.
Hello, I am trying to use sharp on a replica AWS lambda image, and it appears that the vendored linux version of libvips is not properly working.
The lambci images derive ultimately from the "scratch" image of docker, which apparently is one that is super empty. I've tried rebuilding the sharp library in various ways, but it always seems to be downloading the image from the pre-vendored libraries that you have provided.
Any suggestions on how to work around this would be appreciated.