The simplest way to set up connections to AWS CodeCommit repositories is to configure Git credentials for CodeCommit in the IAM console, and then use those credentials for HTTPS connections.
https://docs.aws.amazon.com/codecommit/latest/userguide/setting-up-gc.html