@gradientedge/cdk-utils 8.158.0 → 8.159.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -75,8 +75,9 @@ export declare class LambdaManager {
75
75
  * @param accessPoint
76
76
  * @param mountPath
77
77
  * @param vpcSubnets
78
+ * @param layers
78
79
  */
79
- createLambdaDockerFunction(id: string, scope: CommonConstruct, props: LambdaProps, role: Role | CfnRole, code: DockerImageCode, environment?: any, vpc?: IVpc, securityGroups?: ISecurityGroup[], accessPoint?: IAccessPoint, mountPath?: string, vpcSubnets?: SubnetSelection): DockerImageFunction;
80
+ createLambdaDockerFunction(id: string, scope: CommonConstruct, props: LambdaProps, role: Role | CfnRole, code: DockerImageCode, environment?: any, vpc?: IVpc, securityGroups?: ISecurityGroup[], accessPoint?: IAccessPoint, mountPath?: string, vpcSubnets?: SubnetSelection, layers?: ILayerVersion[]): DockerImageFunction;
80
81
  /**
81
82
  * @summary Method to create a lambda function Alias
82
83
  * @param id scoped id of the resource
@@ -167,8 +167,9 @@ class LambdaManager {
167
167
  * @param accessPoint
168
168
  * @param mountPath
169
169
  * @param vpcSubnets
170
+ * @param layers
170
171
  */
171
- createLambdaDockerFunction(id, scope, props, role, code, environment, vpc, securityGroups, accessPoint, mountPath, vpcSubnets) {
172
+ createLambdaDockerFunction(id, scope, props, role, code, environment, vpc, securityGroups, accessPoint, mountPath, vpcSubnets, layers) {
172
173
  if (!props)
173
174
  throw `Lambda props undefined for ${id}`;
174
175
  const functionName = `${props.functionName}-${scope.props.stage}`;
@@ -194,6 +195,7 @@ class LambdaManager {
194
195
  },
195
196
  filesystem: accessPoint ? aws_lambda_1.FileSystem.fromEfsAccessPoint(accessPoint, mountPath || '/mnt/msg') : undefined,
196
197
  functionName,
198
+ layers,
197
199
  logRetention: scope.props.logRetention ?? props.logRetention,
198
200
  role: role instanceof aws_iam_1.Role ? role : undefined,
199
201
  securityGroups: securityGroups,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gradientedge/cdk-utils",
3
- "version": "8.158.0",
3
+ "version": "8.159.0",
4
4
  "description": "Utilities for AWS CDK provisioning",
5
5
  "main": "dist/index.js",
6
6
  "engines": {
@@ -243,6 +243,7 @@ export class LambdaManager {
243
243
  * @param accessPoint
244
244
  * @param mountPath
245
245
  * @param vpcSubnets
246
+ * @param layers
246
247
  */
247
248
  public createLambdaDockerFunction(
248
249
  id: string,
@@ -255,7 +256,8 @@ export class LambdaManager {
255
256
  securityGroups?: ISecurityGroup[],
256
257
  accessPoint?: IAccessPoint,
257
258
  mountPath?: string,
258
- vpcSubnets?: SubnetSelection
259
+ vpcSubnets?: SubnetSelection,
260
+ layers?: ILayerVersion[]
259
261
  ) {
260
262
  if (!props) throw `Lambda props undefined for ${id}`
261
263
 
@@ -288,6 +290,7 @@ export class LambdaManager {
288
290
  },
289
291
  filesystem: accessPoint ? FileSystem.fromEfsAccessPoint(accessPoint, mountPath || '/mnt/msg') : undefined,
290
292
  functionName,
293
+ layers,
291
294
  logRetention: scope.props.logRetention ?? props.logRetention,
292
295
  role: role instanceof Role ? role : undefined,
293
296
  securityGroups: securityGroups,