Skip to content

Commit 7761a0f

Browse files
author
sai-praveen-os
committed
fix(connectivity_check): include package.json in Lambda zip
PLATEXP-11106 The Lambda was failing with 'Cannot use import statement outside a module' because package.json with type: module was not included in the zip file. Updated build script to include package.json alongside index.js.
1 parent b95249b commit 7761a0f

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

modules/connectivity_check/scripts/build-lambda.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,9 @@ npx tsc
3434
rm -f index.ts tsconfig.json
3535
npm prune --production
3636

37-
# Create zip with compiled handler and node_modules
37+
# Create zip with compiled handler, package.json, and node_modules
3838
cd "$BUILD_DIR"
39-
zip -r "$OUTPUT_ZIP" index.js node_modules/
39+
zip -r "$OUTPUT_ZIP" index.js package.json node_modules/
4040

4141
echo "Lambda package created: $OUTPUT_ZIP"
4242
echo "Size: $(du -h "$OUTPUT_ZIP" | cut -f1)"

0 commit comments

Comments
 (0)