I'm trying to copy files between folders in a mounted directory.
I create a new dir (and set chmod 777) and then copy like so:
async ({ destDir, files }) => {
return await Promise.all(
files.map((filePath) => {
const fileName = path.basename(filePath);
return fs
.copyFile(filePath, path.join(destDir, fileName))
.then(() => fs.chmod(filePath, "777"));
}),
);
}
and getting this error which I can find nothing about:
ENOTSUP: operation not supported on socket, copyfile ....
Any solution would be welcome