Skip to content

Commit 4a27440

Browse files
committed
chore: allow overriding the check for the bundle size
1 parent 28a751d commit 4a27440

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

packages/runtime/src/helpers/verification.ts

+5
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,11 @@ export const checkForRootPublish = ({
105105
}
106106

107107
export const checkZipSize = async (file: string, maxSize: number = LAMBDA_MAX_SIZE): Promise<void> => {
108+
if (!process.env.NETLIFY_CHECK_BUNDLE_SIZE) {
109+
console.log('Skipping the bundle size check. Set env var "NETLIFY_CHECK_BUNDLE_SIZE=true" to enable checking the bundle size')
110+
return
111+
}
112+
108113
if (!existsSync(file)) {
109114
console.warn(`Could not check zip size because ${file} does not exist`)
110115
return

0 commit comments

Comments
 (0)