Last active
October 9, 2019 15:58
-
-
Save raphaelschnaitl/749e662f58e0d3b6d7499403b27e4e48 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alias instances='aws ec2 describe-instances \ | |
--query "Reservations[*].Instances[*]. \ | |
{ \ | |
name: Tags[?Key=='\''Name'\''] |[0].Value, \ | |
instance_id: InstanceId, \ | |
ip_address: PrivateIpAddress, \ | |
state: State.Name \ | |
}" \ | |
--output table' | |
beam() { | |
aws ssm start-session --target $1 | |
} | |
tunnel() { | |
aws ssm start-session --target $1 | |
--document-name AWS-StartPortForwardingSession | |
--parameters '{"portNumber":["'$2'"], "localPortNumber":["'$3'"]}' | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment