0

I have my project on Bitbucket and I am trying to connect BitBucket with AWS CodePipeline. When I try to connect AWS CodePipeline with Bitbucket it says "You have failed to authenticate your account." Error But when I go to my Bitbucket account it says you have authorized AWS CodeStar authentication as you can see here. Bitbucket authorization

I searched on google but didn't get any help. Can someone tell me how I can connect it with Bitbucket repository?

1 Answers1

0

I have resolved my issue. This error has not been defined anywhere. The issue was in my policy. If someone faces this issue you can just add the following policy to your IAM:

{
"Version": "2012-10-17",
"Statement": [
    {
        "Effect": "Allow",
        "Action": [
            "codestar-connections:CreateConnection",
            "codestar-connections:DeleteConnection",
            "codestar-connections:GetConnection",
            "codestar-connections:ListConnections",
            "codestar-connections:GetInstallationUrl",
            "codestar-connections:GetIndividualAccessToken",
            "codestar-connections:ListInstallationTargets",
            "codestar-connections:StartOAuthHandshake",
            "codestar-connections:UpdateConnectionInstallation",
            "codestar-connections:UseConnection",
            "codestar-connections:TagResource",
            "codestar-connections:ListTagsForResource",
            "codestar-connections:UntagResource"
        ],
        "Resource": [
            "*"
        ]
    }
]

}

I was lacking these policies:

            "codestar-connections:GetInstallationUrl",
            "codestar-connections:GetIndividualAccessToken",
            "codestar-connections:ListInstallationTargets",
            "codestar-connections:StartOAuthHandshake",