Setting up users¶
Lab Test’s SSH setup is based on a great article about managing SSH access through IAM. The IAM documentation has more information about using SSH keys and SSH with AWS CodeCommit.
Get the user’s public key. It will look something like:
ssh-rsa EXAMPLE-AfICCQD6m7oRw0uXOjANBgkqhkiG9w0BAQUFADCBiDELMAkGA1UEBhMCVVMxCzAJB gNVBAgTAldBMRAwDgYDVQQHEwdTZWF0dGxlMQ8wDQYDVQQKEwZBbWF6b24xFDASBgNVBAsTC0lBTSBDb2 5zb2xlMRIwEAYDVQQDEwlUZXN0Q2lsYWMxHzAdBgkqhkiG9w0BCQEWEG5vb25lQGFtYXpvbi5jb20wHhc NMTEwNDI1MjA0NTIxWhcNMTIwNDI0MjA0NTIxWjCBiDELMAkGA1UEBhMCVVMxCzAJBgNVBAgTAldBMRAw DgYDVQQHEwdTZWF0dGxlMQ8wDQYDVQQKEwZBbWF6b24xFDAS=EXAMPLE user-name@ip-192-0-2-137
Sign into the IAM console.
In the IAM console, in the navigation pane, choose Users.
Click on the appropriate user. (If you need to create the user, refer to the IAM documentation).
On the user details page, choose the Security Credentials tab.
Scroll down to the SSH keys for AWS CodeCommit section.
Choose Upload SSH public key.
Paste the contents of the SSH public key into the field, and then choose Upload SSH public key.
Done!
Note
Some symbols in the IAM user name are changed for SSH. Specifically:
+
to.plus.
=
to.equal.
,
to.comma.
@
to.at.
Also the length of the converted username must be 32 characters or less.