File tree Expand file tree Collapse file tree 2 files changed +10
-3
lines changed
Expand file tree Collapse file tree 2 files changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -454,7 +454,14 @@ export class ServerlessSpy extends Construct {
454454 layer =
455455 layer ||
456456 new lambda . LayerVersion ( this , 'Extension' , {
457- compatibleRuntimes : [ runtime ] ,
457+ compatibleRuntimes : [
458+ lambda . Runtime . NODEJS_12_X ,
459+ lambda . Runtime . NODEJS_14_X ,
460+ lambda . Runtime . NODEJS_16_X ,
461+ lambda . Runtime . NODEJS_18_X ,
462+ lambda . Runtime . NODEJS_20_X ,
463+ lambda . Runtime . NODEJS_22_X ,
464+ ] ,
458465 compatibleArchitectures : [ architecture ] ,
459466 code : lambda . Code . fromAsset ( this . getExtensionAssetLocation ( ) ) ,
460467 } ) ;
@@ -500,7 +507,7 @@ export class ServerlessSpy extends Construct {
500507 func . addEventSource ( new SqsEventSource ( queue ) ) ;
501508 this . setupForIoT ( func ) ;
502509 const { layer, spyWrapperPath } = this . getExtensionForRuntime (
503- lambda . Runtime . NODEJS_22_X ,
510+ func . runtime ,
504511 func . architecture
505512 ) ! ;
506513 func . addLayers ( layer ) ;
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ export class LambdaStack extends Stack {
1313 const func = new NodejsFunction ( this , 'MyLambda' , {
1414 memorySize : 512 ,
1515 timeout : Duration . seconds ( 5 ) ,
16- runtime : lambda . Runtime . NODEJS_22_X ,
16+ runtime : lambda . Runtime . NODEJS_20_X , // older version to test
1717 handler : 'handler' ,
1818 entry : path . join ( __dirname , '../functions/lambda.ts' ) ,
1919 environment : {
You can’t perform that action at this time.
0 commit comments