UNPKG

maestro

Version:

Maestro is a framework for quickly bootstrapping serverless orchestration workflows with AWS Step Functions

17 lines (12 loc) 389 B
const { iam } = require("../services"); const attachPolicies = (policyArns, roleName) => { const attachPolicyPromises = policyArns.map((policyArn) => { const policyParams = { PolicyArn: policyArn, RoleName: roleName, }; return iam.attachRolePolicy(policyParams).promise(); }); return Promise.all(attachPolicyPromises); }; module.exports = attachPolicies;