From 556d09e6fb2879f9aa5c066ba32c46f368d895e1 Mon Sep 17 00:00:00 2001 From: Rico Huijbers Date: Mon, 18 Feb 2019 10:35:11 +0100 Subject: [PATCH 1/2] fix(codebuild): accept IRole instead of Role Fixes #1778. --- packages/@aws-cdk/aws-codebuild/lib/project.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/@aws-cdk/aws-codebuild/lib/project.ts b/packages/@aws-cdk/aws-codebuild/lib/project.ts index d81ddc85843c2..574056e1b9502 100644 --- a/packages/@aws-cdk/aws-codebuild/lib/project.ts +++ b/packages/@aws-cdk/aws-codebuild/lib/project.ts @@ -460,7 +460,7 @@ export interface CommonProjectProps { * Service Role to assume while running the build. * If not specified, a role will be created. */ - role?: iam.Role; + role?: iam.IRole; /** * Encryption key to use to read and write artifacts From 599da98384cdb9387aa5c190899636f09ec7f252 Mon Sep 17 00:00:00 2001 From: Rico Huijbers Date: Mon, 18 Feb 2019 11:00:42 +0100 Subject: [PATCH 2/2] More I's required! --- packages/@aws-cdk/aws-codebuild/lib/project.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/@aws-cdk/aws-codebuild/lib/project.ts b/packages/@aws-cdk/aws-codebuild/lib/project.ts index 574056e1b9502..e058313819448 100644 --- a/packages/@aws-cdk/aws-codebuild/lib/project.ts +++ b/packages/@aws-cdk/aws-codebuild/lib/project.ts @@ -27,7 +27,7 @@ export interface IProject extends cdk.IConstruct, events.IEventRuleTarget { readonly projectName: string; /** The IAM service Role of this Project. Undefined for imported Projects. */ - readonly role?: iam.Role; + readonly role?: iam.IRole; /** * Convenience method for creating a new {@link PipelineBuildAction CodeBuild build Action}. @@ -182,7 +182,7 @@ export abstract class ProjectBase extends cdk.Construct implements IProject { public abstract readonly projectName: string; /** The IAM service Role of this Project. Undefined for imported Projects. */ - public abstract readonly role?: iam.Role; + public abstract readonly role?: iam.IRole; /** A role used by CloudWatch events to trigger a build */ private eventsRole?: iam.Role; @@ -572,7 +572,7 @@ export class Project extends ProjectBase { /** * The IAM role for this project. */ - public readonly role?: iam.Role; + public readonly role?: iam.IRole; /** * The ARN of the project.