aws / aws-ec2-instance-connect-cli

This is an all-in-one client for EC2 Instance Connect that handles key brokerage and establishing connection to EC2 Instances through an interface near-identical to standard system ssh, sftp, and other utilities.
Apache License 2.0
159 stars 42 forks source link

feat: use only long options to avoid stomping on ssh options #22

Open mariadb-JeffBachtel opened 3 years ago

mariadb-JeffBachtel commented 3 years ago

Currently, mssh uses the short option -t which conflicts with an existing ssh option (ptty allocation).

It would be great if the short option(s) could be removed, or if alternatively an environment variable could be set to eliminate short options altogether.

dko-slapdash commented 2 years ago

I found a hacky work-around for this: add a space before "-t" and quote it:

mssh ... -t i-0adf520869ae1a4ca my-host.com " -t" bash

This works, because mssh calls .strip() for unknown arguments: https://github.com/aws/aws-ec2-instance-connect-cli/blob/470ed6758fae737c28385947b005ecdf4092b08c/ec2instanceconnectcli/input_parser.py#L87