Skip to content

feat(iam): support importing service roles#5701

Merged
mergify[bot] merged 2 commits intoaws:masterfrom
skinny85:fix/iam-import-service-roles
Jan 8, 2020
Merged

feat(iam): support importing service roles#5701
mergify[bot] merged 2 commits intoaws:masterfrom
skinny85:fix/iam-import-service-roles

Conversation

@skinny85
Copy link
Copy Markdown
Contributor

@skinny85 skinny85 commented Jan 7, 2020

Service roles have a different ARN structure
(they have a 'service-role/' segment after the 'role/' part).
Explicitly check for that case when importing a role with such an ARN
(you cannot pass 'service-role/RoleName' as a legal role name).

Fixes #2651


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

Service roles have a different ARN structure
(they have a 'service-role/' segment after the 'role/' part).
Explicitly check for that case when importing a role with such an ARN
(you cannot pass 'service-role/RoleName' as a legal role name).

Fixes aws#2651
@skinny85 skinny85 requested a review from rix0rrr January 7, 2020 22:48
@skinny85 skinny85 self-assigned this Jan 7, 2020
@mergify mergify bot added the contribution/core This is a PR that came from AWS. label Jan 7, 2020
@aws-cdk-automation
Copy link
Copy Markdown
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

Copy link
Copy Markdown
Contributor

@eladb eladb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a bug not a feature :) please fix PR title

@mergify
Copy link
Copy Markdown
Contributor

mergify bot commented Jan 8, 2020

Thank you for contributing! Your pull request is now being automatically merged.

@aws-cdk-automation
Copy link
Copy Markdown
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@mergify
Copy link
Copy Markdown
Contributor

mergify bot commented Jan 8, 2020

Thank you for contributing! Your pull request is now being automatically merged.

@mergify mergify bot merged commit 0f02dad into aws:master Jan 8, 2020
@skinny85 skinny85 deleted the fix/iam-import-service-roles branch January 8, 2020 17:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

contribution/core This is a PR that came from AWS.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CodeBuild: Associating an existing IAM role to a CodeBuild project results in exception

3 participants