diff --git a/core/server/lib/fs/zip-folder.js b/core/server/lib/fs/zip-folder.js index 96ed1377d5..b797a0eba9 100644 --- a/core/server/lib/fs/zip-folder.js +++ b/core/server/lib/fs/zip-folder.js @@ -18,8 +18,10 @@ module.exports = function zipFolder(folderToZip, destination, callback) { archive.on('error', function (err) { callback(err, null); }); - - archive.directory(folderToZip, '/'); + archive.glob(`**/*`, { + cwd: folderToZip, + ignore: ['node_modules/**'] + }); archive.pipe(output); archive.finalize(); };