내용으로 건너뛰기

Encountering BadRequestException: There was an issue setting up your repository. Please try again later.({"message":"403 Forbidden"}) on provisioning aws_amplify_app using Terraform(Gitlab)

0

Encountering BadRequestException: There was an issue setting up your repository. Please try again later.({"message":"403 Forbidden"}) on provisioning aws_amplify_app using Terraform. Although my GitlabPAT has relevant access(api, read_api, read_user, read_repository, write_repository) but still getting it, Although using AWS console it shows repo in my account but my usecase require to do it via terraform

질문됨 일 년 전288회 조회

1개 답변
0

The 403 Forbidden error you're encountering while trying to provision an AWS Amplify app using Terraform with GitLab integration suggests there's an issue with authentication or permissions. Even though your GitLab Personal Access Token (PAT) has the relevant access scopes, there might be other factors causing this problem. Here are some steps you can take to troubleshoot and potentially resolve the issue:

  1. Check token expiration: Ensure your GitLab PAT hasn't expired. If it has, generate a new one with the required scopes.

  2. Verify Amplify permissions: Make sure the IAM role or user associated with your Terraform execution has the necessary permissions to create and manage Amplify resources.

  3. Double-check GitLab permissions: Confirm that the GitLab account associated with the PAT has the correct access level to the repository you're trying to connect.

  4. Refresh or regenerate tokens: Try refreshing your GitLab PAT or generating a new one with the same permissions.

  5. Clear cached credentials: If you're using any form of credential caching, try clearing it and reauthenticating.

  6. Check Amplify service status: Verify that there are no ongoing issues with the AWS Amplify service in your region.

  7. Review Terraform configuration: Ensure your Terraform configuration for the aws_amplify_app resource is correct, including any required parameters for GitLab integration.

  8. Examine Amplify console logs: If possible, check the Amplify console logs for more detailed error messages that might provide additional context.

  9. Consider using AWS CLI: As a workaround, you could try creating the Amplify app using the AWS CLI first, and then import it into your Terraform state.

If the issue persists after trying these steps, you may need to contact AWS support for further assistance, as there could be an underlying problem with the integration between AWS Amplify and GitLab that requires their intervention.

Sources
Missing token in connection: Amplify - GitHub | AWS re:Post
error "access denied" when creating s3 with terraform | AWS re:Post

답변함 일 년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

관련 콘텐츠