conan-aws-lambda
Version:
AWS Lambda plugin for Conan: The Deployer.
23 lines (21 loc) • 489 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = attachRolePolicyStep;
function attachRolePolicyStep(conan, context, stepDone) {
var AWS = context.libraries.AWS;
var iam = new AWS.IAM({
region: conan.config.region
});
iam.attachRolePolicy({
"RoleName": context.parameters.role(),
"PolicyArn": "arn:aws:iam::aws:policy/AWSLambdaExecute"
}, function (error) {
if (error) {
stepDone(error);
} else {
stepDone();
}
});
}