You can also use ec2-instance-connect[0] to enable users to generate ephemeral keys that are valid for a few minutes, authenticated with IAM. The benefit is that it's all native after you've pushed your keys using either aws-cli or mssh. It has more or less the same benefits that SSM has, and you can use the same method with ProxyCommand to establish authentication before connecting. You can also chain it using Proxy…
Show HN: Managing SSH Access to AWS EC2 Instances Using SSM
11–20 of 37 posts
Re: Show HN: Managing SSH Access to AWS EC2 Instances Using SSM
#12You can also use ec2-instance-connect[0] to enable users to generate ephemeral keys that are valid for a few minutes, authenticated with IAM. The benefit is that it's all native after you've pushed your keys using either aws-cli or mssh. It has more or less the same benefits that SSM has, and you can use the same method with ProxyCommand to establish authentication before connecting. You can also chain it using Proxy…
Doesn't that still require the instance to have a public IP? I think the original solution doesn't even need a public IP.
Re: Show HN: Managing SSH Access to AWS EC2 Instances Using SSM
#13Hasn't this been solved by using SSH certificates instead of keys?
Re: Show HN: Managing SSH Access to AWS EC2 Instances Using SSM
#14Seem likes an awfully laboured equivalent of GCP's OSLogin [1]. To SSH into an instance: gcloud compute ssh GCP takes care of generating a key pair. The GCP linux images configure OpenSSH and PAM to check you have relevant IAM permissions. IAP [2] is used in place of a bastion if the instance doesn't have an external IP address. [1]: https://cloud.google.com/compute/docs/instances/managing-ins... [2]: https://cloud.g…
Re: Show HN: Managing SSH Access to AWS EC2 Instances Using SSM
#15Seem likes an awfully laboured equivalent of GCP's OSLogin [1]. To SSH into an instance: gcloud compute ssh GCP takes care of generating a key pair. The GCP linux images configure OpenSSH and PAM to check you have relevant IAM permissions. IAP [2] is used in place of a bastion if the instance doesn't have an external IP address. [1]: https://cloud.google.com/compute/docs/instances/managing-ins... [2]: https://cloud.g…
Session manager doesn't require inbound access iirc. An agent on the machine handles the request via a connection to the SSM service. Your request for a session goes to the SSM service and a websocket connection is established from the machine you need to remote into. A cool solution.
Re: Show HN: Managing SSH Access to AWS EC2 Instances Using SSM
#16Note: the README says "I found myself in a situation where I couldn't easily copy a file from my machine to the server". Note that you can use S3 for that (`aws s3 cp ...`), though you should be careful with permissions on your S3 bucket
Re: Show HN: Managing SSH Access to AWS EC2 Instances Using SSM
#17Seem likes an awfully laboured equivalent of GCP's OSLogin [1]. To SSH into an instance: gcloud compute ssh GCP takes care of generating a key pair. The GCP linux images configure OpenSSH and PAM to check you have relevant IAM permissions. IAP [2] is used in place of a bastion if the instance doesn't have an external IP address. [1]: https://cloud.google.com/compute/docs/instances/managing-ins... [2]: https://cloud.g…
Re: Show HN: Managing SSH Access to AWS EC2 Instances Using SSM
#18Otherwise my developers can't get a Django shell in production for emergencies.
Re: Show HN: Managing SSH Access to AWS EC2 Instances Using SSM
#19Seem likes an awfully laboured equivalent of GCP's OSLogin [1]. To SSH into an instance: gcloud compute ssh GCP takes care of generating a key pair. The GCP linux images configure OpenSSH and PAM to check you have relevant IAM permissions. IAP [2] is used in place of a bastion if the instance doesn't have an external IP address. [1]: https://cloud.google.com/compute/docs/instances/managing-ins... [2]: https://cloud.g…
I'm pretty sure this only works if you use images with Google's sauce added, which means your instances run Google daemons that do things like network, user, and ssh config.
https://cloud.google.com/compute/docs/oslogin/#how_os_login_...
Re: Show HN: Managing SSH Access to AWS EC2 Instances Using SSM
#20Hasn't this been solved by using SSH certificates instead of keys?