Clone a codecommit repo to local machine

0

When I am trying to clone a a codecommit repo to my local machine using HTTPS method I am getting the below error message.

"fatal: unable to access 'https:/...repo url /': The requested URL returned error: 403".

I have followed all the steps mentioned in the aws document and have configured the IAM role & the git credentials as well.

As an alternative I have tried using the SSH method as well. I am facing permission denied & make sure the repo exists error message irrespective of following the document.

I don't want to try using AWS CLI or using the access key ID / secret access key due to compliance restrictions.

Can someone please help me regarding this.

asked a year ago747 views
1 Answer
1

Hi, given what you describe, you should follow "Use Git credentials and HTTPS with CodeCommit (recommended)" in https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_ssh-keys.html

It creates another pair (userid, password) but I used it successfully myself in situation with constraints similar to yours.

profile pictureAWS
EXPERT
answered a year ago
profile pictureAWS
EXPERT
kentrad
reviewed a year ago
  • Thank you so much for your answer. If MFARequired policy is enabled for the IAM user, will this approach work?

  • Hi, thank you so much for your suggestion. I have tried the approach you mentioned, but still facing the same problem. Maybe due to MFARequired policy enabled for the IAM user, this method is not working.

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions