Skip to content

Instantly share code, notes, and snippets.

@miensol
Last active March 11, 2018 21:12
Show Gist options
  • Save miensol/320a231e7a4c97d92256fbc4da4d87d1 to your computer and use it in GitHub Desktop.
Save miensol/320a231e7a4c97d92256fbc4da4d87d1 to your computer and use it in GitHub Desktop.
[LambdaExecutionRole]: new IAM.Role({
AssumeRolePolicyDocument: {
Statement: [{
Effect: "Allow",
Principal: { Service: ["lambda.amazonaws.com"] }, Action: ["sts:AssumeRole"]
}]
},
Path: "/",
ManagedPolicyArns: ["arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole"], Policies: [{
PolicyName: "AllowCallingOtherLambda",
PolicyDocument: {
Version: "2012-10-17",
Statement: [{
Sid: "InvokeLambdaPermission",
Effect: "Allow",
Action: ["lambda:InvokeFunction"],
Resource: "*"
}]
}
}]
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment