maestro
Version:
Maestro is a framework for quickly bootstrapping serverless orchestration workflows with AWS Step Functions
11 lines (8 loc) • 333 B
JavaScript
const { iam } = require("../services");
const getAttachedPolicyArnsByRoleName = async (name) => {
const attachedPolicies = (
await iam.listAttachedRolePolicies({ RoleName: name }).promise()
).AttachedPolicies;
return attachedPolicies.map(({ PolicyArn: arn }) => arn);
};
module.exports = getAttachedPolicyArnsByRoleName;