aws-cdk

How to install python 3.9 on Amazon Linux 2 with cloud-init and CDK

How to install python 3.9 on Amazon Linux 2 with cloud-init and CDK Question: I’m trying to install Python 3.9 an EC2 instance that uses Amazon Linux 2. I tried following this guide: https://computingforgeeks.com/install-latest-python-on-centos-linux/, and I was able to install Python3.9 manually on the EC2 instance by SSH’ing in and running the commands. I’m now …

Total answers: 1

docker login –username AWS –password-stdin https://<accountNumber>.dkr.ecr.<region>.amazonaws.com exited with error code 1:

docker login –username AWS –password-stdin https://<accountNumber>.dkr.ecr.<region>.amazonaws.com exited with error code 1: Question: I’m simply adopting the Eventbridge ETL design pattern and it gives me this error when I deploy: [100%] fail: docker login –username AWS –password-stdin https://315997497220.dkr.ecr.us-west-2.amazonaws.com exited with error code 1: ❌ the-eventbridge-etl failed: Error: Failed to publish one or more assets. See the …

Total answers: 2

How to combine context object with task input in step function Lambda invoke?

How to combine context object with task input in step function Lambda invoke? Question: aws_stepfunctions_tasks.LambdaInvoke.__init__ takes an input_path argument, which defaults to $ – the entire task input. How can I combine that with the context object ($$), since my Lambda needs information from both? Or do I need to use something else, like the …

Total answers: 2

How to correctly code AWS ALB redirection in CDK (python)

How to correctly code AWS ALB redirection in CDK (python) Question: Learning AWS CDK (coming from terraform). I’m currently struggling, how to write a piece of code with will allow me to create redirection as in below screenshot: Code so far which I have: class LoadBalancer(core.Construct): def __init__(self, scope: core.Construct, construct_id: str, props): super().__init__(scope, construct_id) …

Total answers: 3

AWS CDK Python (No Credentials Found)

AWS CDK Python (No Credentials Found) Question: I am trying to using the command CDK Bootstrap after I have set up my virtual environment using the AWS CDK. This is the code for my application that the command above is pulling credentials from. #!/usr/bin/env python3 from aws_cdk import core from hello.hello_stack import MyStack app = …

Total answers: 4

How to install external modules in a Python Lambda Function created by AWS CDK?

How to install external modules in a Python Lambda Function created by AWS CDK? Question: I’m using the Python AWS CDK in Cloud9 and I’m deploying a simple Lambda function that is supposed to send an API request to Atlassian’s API when an Object is uploaded to an S3 Bucket (also created by the CDK). …

Total answers: 6