AWS Architech
Published in

AWS Architech

AWS CDK: attach permissions to existing role

The great thing about AWS CDK is that it handles a lot of things under the hood for you. This includes IAM permissioning.

What if you need to extend the permissions of a service role that’s created by CDK for a resource that is in your CDK?

It’s simple.

Say you have a Lambda function,

const doSomethingLambda = new NodejsFunction(this, 'do-something-lambda', {
memorySize: 1024,
timeout: cdk.Duration.seconds(5),
runtime: lambda.Runtime.NODEJS_14_X




short posts on solutions architecture on the AWS cloud and how to posts

Recommended from Medium

Creating web server using HTTP Module and logging

Spotify App with Angular

Music for everyone with Spotify

5 Amazing Things Pure CSS Can Do


Microservices with NodeJs Using NestJs Redis

Grid-Based Movement in a Top-Down 2D RPG With Phaser 3

Setting up your React Native development environment

Set up API server with Node.js + Express(ES6, Webpack, Flow, Jest, ESLint)

Simple Multipage React Material UI Application

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Nazreen Mohamad

Nazreen Mohamad

Technical Instructor and Software Engineer.

More from Medium

Creating a Cloud Development Environment with AWS CDK

AWS CDK: Specify Runtime Version for CodeBuild Project

What is AWS Private 5G & Is AWS Competing with Telcos?

AWS Lambda Vulnerability Scanning with Open Source Tools