4 ms·
I haven't used it or looked into what it supports, but I did remember this announcement which may interest you: "New – Port Forwarding Using AWS System Manager
by ReidZB 7y ago
I haven't used it or looked into what it supports, but I did remember this announcement which may interest you: "New – Port Forwarding Using AWS System Manager Session Manager": https://aws.amazon.com/blogs/aws/new-port-forwarding-using-aws-system-manager-sessions-manager/ https://aws.amazon.com/blogs/aws/new-port-forwarding-using-a...
To make the ProxyCommand setup a little easier, perhaps you could use `aws ec2 describe-instances` with the appropriate filter? For example, the article I linked uses:
INSTANCE_ID=$(aws ec2 describe-instances \
--filter "Name=tag:Name,Values=$INSTANCE_NAME" \
--query "Reservations[].Instances[?State.Name == 'running'].InstanceId[]" \
--output text)
to grab the instance ID from the Name tag. You could set up a shell script as a ProxyCommand to do this automatically, although beware that ProxyCommand's %h will always lowercase the input...