Skip to content

Commit

Permalink
Fix pnpm for linux (#1309)
Browse files Browse the repository at this point in the history
fix: resolved pnpm compatibility for Linux function deployments
  • Loading branch information
tudorpip authored Aug 21, 2024
1 parent 846b7d7 commit 0ce9e5b
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/commands/deploy/genezio.ts
Original file line number Diff line number Diff line change
Expand Up @@ -581,6 +581,16 @@ export async function functionToCloudInput(

// copy everything to the temporary folder
await fsExtra.copy(path.join(backendPath, functionElement.path), tmpFolderPath);
if (fsExtra.pathExistsSync(path.join(tmpFolderPath, "node_modules", ".pnpm"))) {
await fsExtra.remove(path.join(tmpFolderPath, "node_modules", ".pnpm"));
await fsExtra.copy(
path.join(backendPath, functionElement.path, "node_modules", ".pnpm"),
path.join(tmpFolderPath, "node_modules", ".pnpm"),
{
dereference: true,
},
);
}

const unzippedBundleSize = await getBundleFolderSizeLimit(tmpFolderPath);

Expand Down

0 comments on commit 0ce9e5b

Please sign in to comment.