Skip to main content
IAM Policy Map

AWSCodeBuildReadOnlyAccess

ReaderAWS managedActivePermissions reviewedShow on mapCompare

Summary

Provides read only access to AWS CodeBuild via the AWS Management Console. Also attach AmazonS3ReadOnlyAccess to provide access to download build artifacts.

Permissions imported from the AWS Managed Policy Reference Guide; other sections pending editorial review.

Identity

ARN
arn:aws:iam::aws:policy/AWSCodeBuildReadOnlyAccess
Default version
v15
Created
Last edited
Services
cloudwatch, codebuild, codecommit, codestar-connections, codestar-notifications, events, logs

Control-plane actions (42)

By access level: 24 List, 18 Read.

Control-plane actions by service
ServiceGrantedAccess levels and limitsGranted by
CodeBuild29 of 6718 List, 11 Read; 0 restricted, 0 conditionalcodebuild:BatchGet*, codebuild:DescribeCodeCoverages, codebuild:DescribeTestCases, codebuild:GetResourcePolicy, codebuild:List*
CodeCommit3 of 913 Read; 0 restricted, 0 conditionalcodecommit:GetBranch, codecommit:GetCommit, codecommit:GetRepository
CodeStar Connections2 of 381 List, 1 Read; 2 restricted, 0 conditionalcodestar-connections:GetConnection, codestar-connections:ListConnections
CodeStar Notifications4 of 133 List, 1 Read; 1 restricted, 1 conditionalcodestar-notifications:DescribeNotificationRule, codestar-notifications:ListEventTypes, codestar-notifications:ListNotificationRules, codestar-notifications:ListTargets
EventBridge3 of 712 List, 1 Read; 0 restricted, 0 conditionalevents:DescribeRule, events:ListRuleNamesByTarget, events:ListTargetsByRule
CloudWatch Logs1 of 1331 Read; 0 restricted, 0 conditionallogs:GetLogEvents
CodeBuild: 29 actions
  • codebuild:BatchGetBuildBatches (Read)
  • codebuild:BatchGetBuilds (Read)
  • codebuild:BatchGetCommandExecutions (Read)
  • codebuild:BatchGetFleets (Read)
  • codebuild:BatchGetProjects (Read)
  • codebuild:BatchGetReportGroups (Read)
  • codebuild:BatchGetReports (Read)
  • codebuild:BatchGetSandboxes (Read)
  • codebuild:DescribeCodeCoverages (Read)
  • codebuild:DescribeTestCases (Read)
  • codebuild:GetResourcePolicy (Read)
  • codebuild:ListBuildBatches (List)
  • codebuild:ListBuildBatchesForProject (List)
  • codebuild:ListBuilds (List)
  • codebuild:ListBuildsForProject (List)
  • codebuild:ListCommandExecutionsForSandbox (List)
  • codebuild:ListConnectedOAuthAccounts (List)
  • codebuild:ListCuratedEnvironmentImages (List)
  • codebuild:ListFleets (List)
  • codebuild:ListProjects (List)
  • codebuild:ListReportGroups (List)
  • codebuild:ListReports (List)
  • codebuild:ListReportsForReportGroup (List)
  • codebuild:ListRepositories (List)
  • codebuild:ListSandboxes (List)
  • codebuild:ListSandboxesForProject (List)
  • codebuild:ListSharedProjects (List)
  • codebuild:ListSharedReportGroups (List)
  • codebuild:ListSourceCredentials (List)
CodeCommit: 3 actions
  • codecommit:GetBranch (Read)
  • codecommit:GetCommit (Read)
  • codecommit:GetRepository (Read)
CodeStar Connections: 2 actions
  • codestar-connections:GetConnection (Read)
  • codestar-connections:ListConnections (List)
CodeStar Notifications: 4 actions
  • codestar-notifications:DescribeNotificationRule (Read)
  • codestar-notifications:ListEventTypes (List)
  • codestar-notifications:ListNotificationRules (List)
  • codestar-notifications:ListTargets (List)
EventBridge: 3 actions
  • events:DescribeRule (Read)
  • events:ListRuleNamesByTarget (List)
  • events:ListTargetsByRule (List)
CloudWatch Logs: 1 actions
  • logs:GetLogEvents (Read)

Data-plane actions (1)

By access level: 1 Read.

Data-plane actions by service
ServiceGrantedAccess levels and limitsGranted by
CloudWatch1 of 51 Read; 0 restricted, 0 conditionalcloudwatch:GetMetricStatistics
CloudWatch: 1 actions
  • cloudwatch:GetMetricStatistics (Read)

Excluded and conditional actions

No patterns are excluded by NotAction or Deny statements.

Resource scope and attachment

Resource scope across granted actions: mixed.

Can be attached: Yes, to users, groups and roles.

Why this tier

  • Grants only List and Read actions.

Guidance

Pending editorial review. The permission data on this page comes straight from AWS; this section will be filled in once a reviewed guide exists.

Same service

Same domain

Frequently asked questions

Pending editorial review. The permission data on this page comes straight from AWS; this section will be filled in once a reviewed guide exists.

Policy JSON

Download policy.json

{
  "Statement": [
    {
      "Sid": "AWSServicesAccess",
      "Action": [
        "codebuild:BatchGet*",
        "codebuild:GetResourcePolicy",
        "codebuild:List*",
        "codebuild:DescribeTestCases",
        "codebuild:DescribeCodeCoverages",
        "codecommit:GetBranch",
        "codecommit:GetCommit",
        "codecommit:GetRepository",
        "cloudwatch:GetMetricStatistics",
        "events:DescribeRule",
        "events:ListTargetsByRule",
        "events:ListRuleNamesByTarget",
        "logs:GetLogEvents"
      ],
      "Effect": "Allow",
      "Resource": "*"
    },
    {
      "Sid": "CodeStarConnectionsUserAccess",
      "Effect": "Allow",
      "Action": [
        "codestar-connections:ListConnections",
        "codestar-connections:GetConnection"
      ],
      "Resource": [
        "arn:aws:codestar-connections:*:*:connection/*",
        "arn:aws:codeconnections:*:*:connection/*"
      ]
    },
    {
      "Sid": "CodeStarNotificationsPowerUserAccess",
      "Effect": "Allow",
      "Action": [
        "codestar-notifications:DescribeNotificationRule"
      ],
      "Resource": "*",
      "Condition": {
        "ArnLike": {
          "codestar-notifications:NotificationsForResource": "arn:aws:codebuild:*:*:project/*"
        }
      }
    },
    {
      "Sid": "CodeStarNotificationsListAccess",
      "Effect": "Allow",
      "Action": [
        "codestar-notifications:ListNotificationRules",
        "codestar-notifications:ListEventTypes",
        "codestar-notifications:ListTargets"
      ],
      "Resource": "*"
    }
  ],
  "Version": "2012-10-17"
}

Version history

Current version v15, edited by AWS on 2026-02-12. Version history is recorded from 2026-11-11. Earlier versions are in the IAM console under Policy versions.

Attach snippets

AWS CLI

aws iam attach-role-policy --role-name ROLE_NAME --policy-arn arn:aws:iam::aws:policy/AWSCodeBuildReadOnlyAccess
aws iam attach-user-policy --user-name USER_NAME --policy-arn arn:aws:iam::aws:policy/AWSCodeBuildReadOnlyAccess
aws iam attach-group-policy --group-name GROUP_NAME --policy-arn arn:aws:iam::aws:policy/AWSCodeBuildReadOnlyAccess

CloudFormation

Resources:
  ExampleRole:
    Type: AWS::IAM::Role
    Properties:
      AssumeRolePolicyDocument: {}  # replace with your trust policy
      ManagedPolicyArns:
        - arn:aws:iam::aws:policy/AWSCodeBuildReadOnlyAccess

Terraform

resource "aws_iam_role_policy_attachment" "awscodebuildreadonlyaccess" {
  role       = aws_iam_role.example.name
  policy_arn = "arn:aws:iam::aws:policy/AWSCodeBuildReadOnlyAccess"
}

CDK (TypeScript)

role.addManagedPolicy(
  iam.ManagedPolicy.fromAwsManagedPolicyName("AWSCodeBuildReadOnlyAccess"),
);

Sources

Pending editorial review. No editorial sources are listed yet.