Overview : | |
To upload/connect AWS CodeCommit repository with Local Machine/Local Repository/Code, we need to establish a connection between AWS Codebuild and our PCHere we have Three ways , in among them SSH is a secured way using password less SSH connection, with this reason we using this ssh connection method To Implement this SSH connection we need(i) Create an IAM User for CodeCommit(ii) Attach CodeCommit Repository permission policy to IAM user(above created)(iii) Generate SSH Token at git bash, upload the public key token to IAM user (above created)(iv) Generate config file at Git Bash .ssh folder with the configuration ofPublic Key ID from IAM user , Private key and AWS connection string(v) verifying the connection(vi) If the connection is successful then we are ready to upload the repository from local machine to AWS CodeCommit Repository | |
Step 1 – Open IAM Service :
Step 2 – Create IAM User : Click on Users at sidebar
Step 3 – Add users : Click on Add users
Step 4 – Specify user details : Enter User name and Click on Next
Step 5 – Set permissions : Select Attach policies directly, next click on Create policy
Permissions options : Select |
Permissions policies : Click on choose policy When you click on a new tab open for creating the policy |
When after clicking on Create policy , new tab opens with Create policy page
Policy creation : search and select(i) service : codecommit |
(ii)Actions :Specify the actions allowed in CodeCommit Tick All CodeCommit actions (codecommit:*) |
Step 7 – Resources : Select ARN
Step 7 – Add ARN : Add Region(Which region CodeCommit Repository Created) , Account(auto updates) and Repository name : copy and paste the CodeCommit Repository name and next click on Add
Next Click on Tags
Step 8 – Add Tags :
Step 9 – Review policy : Review details and click on Create policy button at bottom
When after clicking, policy generated, redirects to policy page , there we can we see the newly created policy
Step 10 – Attach policy to IAM user : Get back to IAM Creation tab, click on refresh the permission icon , next search for newly created policy , select and attach policy to IAM user
Step 10 – Review and create : verify and Create user
When after clicking Create user, Redirects users page and show newly created username in the list,click on the user
Select the Security Credentials tab after clicking/opening the username
Step 11 – SSH public keys for AWS CodeCommit (0) : Here we need to upload the SSH Public key