Skip to content

Instantly share code, notes, and snippets.

View NimaSaed's full-sized avatar
🛡️

Nima Saed NimaSaed

🛡️
View GitHub Profile
import boto3
def lambda_handler(event, context):
print("Instance ID")
print("---------------")
print(event["detail"]["resources"][0]["id"])
print("---------------")
ssm = boto3.client('ssm')

Keybase proof

I hereby claim:

  • I am nimasaed on github.
  • I am nimasaed (https://keybase.io/nimasaed) on keybase.
  • I have a public key ASADMOFyzeubH2D7m2IOHMAqInLF-f1LGlIvGL8Qqu909Qo

To claim this, I am signing this object:

@NimaSaed
NimaSaed / bashrc
Last active February 18, 2022 09:16
Bash AWS Profile Changer
# Add this function to the end of your ~/.bashrc
function aws_profile() {
local aws_home="$HOME/.aws"
local profiles=(`\
cat ${aws_home}/config | \
grep profile | \
sed 's/\[//g;s/\]//g' | \