我試着按照AWS的說明爲我的用戶設置ECR授權,方法是給我的用戶AmazonEC2ContainerRegistryFullAccess
策略。AWS ECR GetAuthorizationToken
但是,當我嘗試在我的電腦上運行aws ecr get-login
時出現錯誤,我沒有權限。
An error occurred (AccessDeniedException) when calling the GetAuthorizationToken operation: User: arn:aws:iam::ACCOUNT_NUMBER:user/MY_USER is not authorized to perform: ecr:GetAuthorizationToken on resource: *
我做錯了什麼?
aws get-session-token可以從MFA獲取令牌 - http://docs.aws.amazon.com/cli/latest/reference/sts/get-session-token.html –