https://pulumi.com logo
Title
n

narrow-cpu-35517

01/23/2023, 11:30 PM
Using this role with below lambda function
const plaidHandlerFunction = new aws.lambda.Function(
    "plaidHandlerFunction",
    {
      name: "plaidHandlerFunction",
      // Upload the code for our Lambda from the "./app" directory:
      code: new pulumi.asset.AssetArchive({
        ".": new pulumi.asset.FileArchive("./app/lambda-functions/plaid-lambda-function")
      }),
      handler: "index.handler",
      runtime: "nodejs16.x",
      role: plaidHandlerRole.arn,
      environment: {
        variables: {
          SQS_QUEUE: config.get("sqsQueue") || ""
        }
      }
    },
    {
      dependsOn: [awsLambdaExecutePolicyAttachment, plaidSqsRolePolicyAttachment, plaidCloudwatchRolePolicyAttachment]
    }
  );