AWS
This post summarizes how to perform AssumeRole using Boto3. Introduction Assuming Roles with Boto3 Implementing the AssumeRole function Example Usage Conclusion References Introduction There are many situations where you need to AssumeRole…
This post explains the CloudFormation template that sets up the backend (S3/DynamoDB) to store Terraform state. Introduction CloudFormation Template to Provision Terraform Backend Conclusion References Introduction How to provision the bac…
This is a quick note on how to output DEBUG-level logs using the AWS CLI. Introduction Outputting DEBUG-Level Logs with AWS CLI How to do it Example Execution Conclusion References Introduction There are times when you want to run AWS CLI …
This is a quick memo on how to retrieve all AWS service names (subcommands) provided via AWS CLI. Introduction How to List All Available Services in AWS CLI Method Example Conclusion References Introduction Sometimes you might want to list…
How to fix the issue where searching with grep the output of aws help doesn't work as expected? Introduction Why You Can't Grep AWS CLI Help Output Cause Solution Example Conclusion References Introduction When you try to grep or use sed o…
This post summarizes how to use !FindInMap inside !Sub in AWS CloudFormation. Introduction Using !FindInMap Inside !Sub Conclusion References Introduction CloudFormation's !Sub is a function that substitutes values into a string, while !Fi…
This post summarizes how to work as ec2-user or root user in AWS Systems Manager (SSM) Session Manager. Introduction Working as ec2-user or root with Session Manager Current Situation: Shell Access as ssm-user Solution: sudo su --login ec2…
This article summarizes how to fix the following error that occurs when using Python's json module for JSON conversion: "Object of type datetime is not JSON serializable" Introduction Background Solutions Preliminary: The default Parameter…
This post explains the differences between the AWS CLI commands s3 cp and s3 sync. Introduction Key Differences Between cp and sync Comparing Descriptions Comparing Command Options Comparing Command Behaviors Simple S3 copy Copy updated S3…
This article summarizes how to handle errors in boto3, AWS SDK for Python. Introduction Handling Errors in boto3 Using client.exceptions Using botocore.exceptions Example Code Handling BucketAlreadyExists error in S3 create_bucket Handling…
This post summarizes the differences between boto3 and boto, the origins of "boto" itself, and the history of the AWS SDK for Python. Introduction The History of AWS SDK for Python Differences Between boto3 and boto What Happened to boto2?…
This post provides an overview of how S3 bucket policies and IAM policies interact for both same-account and cross-account access scenarios. Introduction S3 Bucket Policies and IAM Policies: How They Work Together Conclusion First Preparat…