2

I linked a repo in CodeCommit to Sagemaker. However when I try to start an instance with that repo it fails and I get a message:

fatal: unable to access 'https://git-codecommit.us-east-1.amazonaws.com/v1/repos/MyRepo/': The requested URL returned error: 403

I think maybe it has something to do with the IAM role. Is there some policy I should add to the AmazonSageMaker-ExecutionRole. I am completely new to this so please excuse any incorrect usage of terms here.

HashBr0wn
  • 387
  • 1
  • 11

1 Answers1

2

This is presumably caused by your IAM role ; if you used the UI to create a role, I think by default, it creates a role requiring resources to have "sagemaker" in their ARN (Codecommit repos, S3 buckets...). So you have 2 options:

  • Try renaming your repo eg "myrepo-sagemaker"
  • Or edit (ask your admin if you don't have the ability) your SM IAM role to be allowed to access MyRepo
Olivier Cruchant
  • 3,747
  • 15
  • 18