Questions tagged [aws-cdk]

The AWS CDK is an infrastructure modeling framework that allows you to define your cloud resources using an imperative programming interface.

The AWS CDK is an infrastructure modeling framework that allows you to define your cloud resources using an imperative programming interface, currently TypeScript/JavaScript, Python, Java, C# and (beta) Go.

Developers can use one of the supported programming languages to define reusable cloud components called Constructs, which are composed together into Stacks and Apps.

The AWS CDK Toolkit is a command-line tool for interacting with CDK apps. It allows developers to synthesize artifacts such as AWS CloudFormation Templates, deploy stacks to development AWS accounts and “diff” against a deployed stack to understand the impact of a code change.

The AWS Construct Library includes a module for each AWS service with constructs that offer rich APIs that encapsulate the details of how to use AWS. The AWS Construct Library aims to reduce the complexity and glue-logic required when integrating various AWS services to achieve your goals on AWS.

3488 questions
1
vote
1 answer

Getting values from the cdk command and using them in code

Is there a possible way to obtain the value from a cdk command. Say, if there are two profiles namely foo, boo and during syth I would mention them as cdk synth --profile foo and later in the code there is a need to change a property as foo (i:e:…
Krithick S
  • 408
  • 3
  • 15
1
vote
1 answer

How can I specify a branch folder of a monorepo when deploying an Amplify app using the CDK?

Currently using the aws console is simple: But I can't find the way to do it using the CDK.
atoledo
  • 435
  • 5
  • 12
1
vote
0 answers

S3 Access Denied even when running the CDK with AdministratorAccess

I am getting below error, as those are in AWS Console, please find the attached screenshots: I was just cloning this project https://github.com/aws-samples/aws-dev-hour-backend and trying it out. Also I have bootstrap using cdk bootstrap \ …
Smit
  • 2,078
  • 2
  • 17
  • 40
1
vote
1 answer

AWS API Gateway MockIntegration does not accept Content-Type `application/vnd.nasa.cmr.umm+json;version=1.6.3`

I'm currently attempting to create a mock integration using the python AWS CDK for the purpose of running integration tests in an app. This app needs to query an external API to validate a payload. The endpoint expects a Content-Type…
1
vote
1 answer

route53 returns forbidden for custom domain with API Gateway

I'm using AWS CDK to create an APIGateway. I want to attach a custom domain to my api so I can use api.findtechjobs.io. In the console, I can see I have a custom domain attached, however I always get a 403 response when using my custom domain. Below…
1
vote
1 answer

How to get resource out of the CfnStack?

I used the CfnInclude to import a cloudformation template to my cdk code: template= _cfn_include.CfnInclude(self, 'template', template_file = "aws-waf-security-automations.yaml") After that I used the get_resource() to get one of the…
Roland
  • 607
  • 1
  • 7
  • 12
1
vote
1 answer

Create encryption for all log group of Cloudwatch at a time using aws cli or CDK

In order to create an encryption for CloudWatch all log groups using the CLI command , individual log group names are required. Is there a way to encrypt all log groups in CloudWatch at a time using a single command? or is there a way to do it using…
1
vote
1 answer

How to run non CDK code during an AWS CDK deployment

My aws-app has multiple AWS CDK stacks among those stack is also RDS. My goal is to execute code that creates new databases and tables in the newly provisioned DB before my software is actually deployed. The problem is that the code that creates the…
Vad1mo
  • 5,156
  • 6
  • 36
  • 65
1
vote
1 answer

File/Folder Structure For Nextjs Frontend & AWS CDK Backend

I was wondering if there were best practices regarding folder structure when creating websites with serverless backends. Right now I have a Nextjs frontend and an AWS CDK backend. The current folder structure I am using has the cdk backend embedded…
1
vote
1 answer

API Gateway GET Method Request URL Query String Parameters using AWS CDK

I am configuring API gateway using CDK and I am struggling with URL Query String Parameters in GET Method Request. I could find examples for the integration request but nothing for the Method request. These are my URL Query String Parameters defined…
1
vote
1 answer

AWS CDK create Lambda from image

I am a new to AWS world. I am working on a project to build a server less application and as part of that I have created 4 lambda which works fine. Next I am trying to create a deployment pipe line using CDK; below is what I am trying to do. create…
Rahul
  • 47
  • 7
1
vote
2 answers

Allow AWS Aurora VPC Cluster to be publicly accessible using CDK

I have tried configuring the RDS cluster using cluster.connections.allowDefaultPortFromAnyIpv4(); but still I am not able to connect to my postgres instance, it keeps timing out. I've been trying to figure this out from 2 days but still no luck, not…
1
vote
1 answer

Having Problems with tests in CDK-Workshop (typescript): Inline source not allowed for nodejs14.x

I am currently working through the cdk-workshop provided by amazon: https://cdkworkshop.com. I followed all the steps (at least I hope) and have created a test program and deployed it. I the current step I am tasked to create assertion tests for my…
Daniel Töws
  • 347
  • 1
  • 5
  • 21
1
vote
0 answers

define API mappings for apigateway in CDK

how can I deploy the following setting to my apigateway using cdk? relevant part of my CDK-stack for my API: .... const restApi = new apigateway.LambdaRestApi(this, "dyndns-api", { handler: dyndnsLambda, proxy: false, domainName: { …
globus243
  • 710
  • 1
  • 15
  • 31
1
vote
1 answer

How to get a value from SecretString returned from AwsCustomResource (service: 'SecretsManager', action: 'getSecretValue') as plain text?

I'm modifying the code from this workshop to do cross-account rather than cross-region. https://cdk-advanced.workshop.aws/start.html The first thing I did was install and configure cdk-assume-role-credential-plugin and bootstrapped. In the workshop…
bravogolfgolf
  • 357
  • 2
  • 11
1 2 3
99
100