{ "version": 4, "terraform_version": "1.3.7", "serial": 137, "lineage": "7413839f-c67c-02f5-4933-fcb84251bb29", "outputs": {}, "resources": [ { "module": "module.codebuild", "mode": "data", "type": "aws_caller_identity", "name": "default", "provider": "provider[\"registry.terraform.io/hashicorp/aws\"]", "instances": [ { "schema_version": 0, "attributes": { "account_id": "259692501178", "arn": "arn:aws:iam::259692501178:user/yuki", "id": "259692501178", "user_id": "AIDAI6K42G2YZESELYLD4" }, "sensitive_attributes": [] } ] }, { "module": "module.codebuild", "mode": "data", "type": "aws_iam_policy_document", "name": "combined_permissions", "provider": "provider[\"registry.terraform.io/hashicorp/aws\"]", "instances": [ { "schema_version": 0, "attributes": { "id": "1570789323", "json": "{\n \"Version\": \"2012-10-17\",\n \"Statement\": [\n {\n \"Sid\": \"\",\n \"Effect\": \"Allow\",\n \"Action\": [\n \"ssm:GetParameters\",\n \"secretsmanager:GetSecretValue\",\n \"logs:PutLogEvents\",\n \"logs:CreateLogStream\",\n \"logs:CreateLogGroup\",\n \"iam:PassRole\",\n \"ecs:RunTask\",\n \"ecr:UploadLayerPart\",\n \"ecr:PutImage\",\n \"ecr:InitiateLayerUpload\",\n \"ecr:GetAuthorizationToken\",\n \"ecr:CompleteLayerUpload\",\n \"ecr:BatchCheckLayerAvailability\",\n \"codecommit:GitPull\"\n ],\n \"Resource\": \"*\"\n }\n ]\n}", "override_json": null, "override_policy_documents": [ "{\n \"Version\": \"2012-10-17\",\n \"Statement\": [\n {\n \"Sid\": \"\",\n \"Effect\": \"Allow\",\n \"Action\": [\n \"ssm:GetParameters\",\n \"secretsmanager:GetSecretValue\",\n \"logs:PutLogEvents\",\n \"logs:CreateLogStream\",\n \"logs:CreateLogGroup\",\n \"iam:PassRole\",\n \"ecs:RunTask\",\n \"ecr:UploadLayerPart\",\n \"ecr:PutImage\",\n \"ecr:InitiateLayerUpload\",\n \"ecr:GetAuthorizationToken\",\n \"ecr:CompleteLayerUpload\",\n \"ecr:BatchCheckLayerAvailability\",\n \"codecommit:GitPull\"\n ],\n \"Resource\": \"*\"\n }\n ]\n}" ], "policy_id": null, "source_json": null, "source_policy_documents": null, "statement": null, "version": "2012-10-17" }, "sensitive_attributes": [] } ] }, { "module": "module.codebuild", "mode": "data", "type": "aws_iam_policy_document", "name": "permissions", "provider": "provider[\"registry.terraform.io/hashicorp/aws\"]", "instances": [ { "index_key": 0, "schema_version": 0, "attributes": { "id": "1570789323", "json": "{\n \"Version\": \"2012-10-17\",\n \"Statement\": [\n {\n \"Sid\": \"\",\n \"Effect\": \"Allow\",\n \"Action\": [\n \"ssm:GetParameters\",\n \"secretsmanager:GetSecretValue\",\n \"logs:PutLogEvents\",\n \"logs:CreateLogStream\",\n \"logs:CreateLogGroup\",\n \"iam:PassRole\",\n \"ecs:RunTask\",\n \"ecr:UploadLayerPart\",\n \"ecr:PutImage\",\n \"ecr:InitiateLayerUpload\",\n \"ecr:GetAuthorizationToken\",\n \"ecr:CompleteLayerUpload\",\n \"ecr:BatchCheckLayerAvailability\",\n \"codecommit:GitPull\"\n ],\n \"Resource\": \"*\"\n }\n ]\n}", "override_json": null, "override_policy_documents": null, "policy_id": null, "source_json": null, "source_policy_documents": null, "statement": [ { "actions": [ "codecommit:GitPull", "ecr:BatchCheckLayerAvailability", "ecr:CompleteLayerUpload", "ecr:GetAuthorizationToken", "ecr:InitiateLayerUpload", "ecr:PutImage", "ecr:UploadLayerPart", "ecs:RunTask", "iam:PassRole", "logs:CreateLogGroup", "logs:CreateLogStream", "logs:PutLogEvents", "secretsmanager:GetSecretValue", "ssm:GetParameters" ], "condition": [], "effect": "Allow", "not_actions": [], "not_principals": [], "not_resources": [], "principals": [], "resources": [ "*" ], "sid": "" } ], "version": "2012-10-17" }, "sensitive_attributes": [] } ] }, { "module": "module.codebuild", "mode": "data", "type": "aws_iam_policy_document", "name": "role", "provider": "provider[\"registry.terraform.io/hashicorp/aws\"]", "instances": [ { "schema_version": 0, "attributes": { "id": "442947395", "json": "{\n \"Version\": \"2012-10-17\",\n \"Statement\": [\n {\n \"Sid\": \"\",\n \"Effect\": \"Allow\",\n \"Action\": \"sts:AssumeRole\",\n \"Principal\": {\n \"Service\": \"codebuild.amazonaws.com\"\n }\n }\n ]\n}", "override_json": null, "override_policy_documents": null, "policy_id": null, "source_json": null, "source_policy_documents": null, "statement": [ { "actions": [ "sts:AssumeRole" ], "condition": [], "effect": "Allow", "not_actions": [], "not_principals": [], "not_resources": [], "principals": [ { "identifiers": [ "codebuild.amazonaws.com" ], "type": "Service" } ], "resources": [], "sid": "" } ], "version": "2012-10-17" }, "sensitive_attributes": [] } ] }, { "module": "module.codebuild", "mode": "data", "type": "aws_region", "name": "default", "provider": "provider[\"registry.terraform.io/hashicorp/aws\"]", "instances": [ { "schema_version": 0, "attributes": { "description": "Asia Pacific (Tokyo)", "endpoint": "ec2.ap-northeast-1.amazonaws.com", "id": "ap-northeast-1", "name": "ap-northeast-1" }, "sensitive_attributes": [] } ] }, { "module": "module.codebuild", "mode": "managed", "type": "aws_codebuild_project", "name": "default", "provider": "provider[\"registry.terraform.io/hashicorp/aws\"]", "instances": [ { "index_key": 0, "schema_version": 0, "attributes": { "arn": "arn:aws:codebuild:ap-northeast-1:259692501178:project/growi-official-image-builder", "artifacts": [ { "artifact_identifier": "", "bucket_owner_access": "", "encryption_disabled": false, "location": "", "name": "", "namespace_type": "", "override_artifact_name": false, "packaging": "", "path": "", "type": "NO_ARTIFACTS" } ], "badge_enabled": false, "badge_url": "", "build_batch_config": [ { "combine_artifacts": false, "restrictions": [ { "compute_types_allowed": [], "maximum_builds_allowed": 100 } ], "service_role": "arn:aws:iam::259692501178:role/growi-official-image-builder", "timeout_in_mins": 2160 } ], "build_timeout": 60, "cache": [ { "location": "", "modes": [ "LOCAL_DOCKER_LAYER_CACHE", "LOCAL_CUSTOM_CACHE" ], "type": "LOCAL" } ], "concurrent_build_limit": 0, "description": "The CodeBuild Project for GROWI official docker image", "encryption_key": "arn:aws:kms:ap-northeast-1:259692501178:alias/aws/s3", "environment": [ { "certificate": "", "compute_type": "BUILD_GENERAL1_LARGE", "environment_variable": [ { "name": "AWS_REGION", "type": "PLAINTEXT", "value": "ap-northeast-1" }, { "name": "AWS_ACCOUNT_ID", "type": "PLAINTEXT", "value": "259692501178" }, { "name": "IMAGE_REPO_NAME", "type": "PLAINTEXT", "value": "UNSET" }, { "name": "IMAGE_TAG", "type": "PLAINTEXT", "value": "latest" }, { "name": "NO_ADDITIONAL_BUILD_VARS", "type": "PLAINTEXT", "value": "TRUE" } ], "image": "aws/codebuild/standard:6.0", "image_pull_credentials_type": "CODEBUILD", "privileged_mode": true, "registry_credential": [], "type": "LINUX_CONTAINER" } ], "file_system_locations": [], "id": "arn:aws:codebuild:ap-northeast-1:259692501178:project/growi-official-image-builder", "logs_config": [ { "cloudwatch_logs": [ { "group_name": "", "status": "ENABLED", "stream_name": "" } ], "s3_logs": [ { "bucket_owner_access": "", "encryption_disabled": false, "location": "", "status": "DISABLED" } ] } ], "name": "growi-official-image-builder", "project_visibility": "PRIVATE", "public_project_alias": "", "queued_timeout": 480, "resource_access_role": "", "secondary_artifacts": [], "secondary_source_version": [], "secondary_sources": [], "service_role": "arn:aws:iam::259692501178:role/growi-official-image-builder", "source": [ { "auth": [], "build_status_config": [], "buildspec": "packages/app/docker/codebuild/buildspec/root.yml", "git_clone_depth": 1, "git_submodules_config": [], "insecure_ssl": false, "location": "https://github.com/weseek/growi.git", "report_build_status": false, "type": "GITHUB" } ], "source_version": "refs/heads/support/build-with-codebuild", "tags": { "Name": "growi-official-image-builder" }, "tags_all": { "Name": "growi-official-image-builder" }, "vpc_config": [] }, "sensitive_attributes": [], "private": "bnVsbA==", "dependencies": [ "module.codebuild.aws_codebuild_source_credential.authorization", "module.codebuild.aws_iam_role.default", "module.codebuild.aws_s3_bucket.cache_bucket", "module.codebuild.data.aws_caller_identity.default", "module.codebuild.data.aws_region.default" ] } ] }, { "module": "module.codebuild", "mode": "managed", "type": "aws_iam_policy", "name": "default", "provider": "provider[\"registry.terraform.io/hashicorp/aws\"]", "instances": [ { "index_key": 0, "schema_version": 0, "attributes": { "arn": "arn:aws:iam::259692501178:policy/service-role/growi-official-image-builder", "description": "", "id": "arn:aws:iam::259692501178:policy/service-role/growi-official-image-builder", "name": "growi-official-image-builder", "name_prefix": null, "path": "/service-role/", "policy": "{\"Statement\":[{\"Action\":[\"ssm:GetParameters\",\"secretsmanager:GetSecretValue\",\"logs:PutLogEvents\",\"logs:CreateLogStream\",\"logs:CreateLogGroup\",\"iam:PassRole\",\"ecs:RunTask\",\"ecr:UploadLayerPart\",\"ecr:PutImage\",\"ecr:InitiateLayerUpload\",\"ecr:GetAuthorizationToken\",\"ecr:CompleteLayerUpload\",\"ecr:BatchCheckLayerAvailability\",\"codecommit:GitPull\"],\"Effect\":\"Allow\",\"Resource\":\"*\",\"Sid\":\"\"}],\"Version\":\"2012-10-17\"}", "policy_id": "ANPATY5XBDC5HSN3IY7CW", "tags": { "Name": "growi-official-image-builder" }, "tags_all": { "Name": "growi-official-image-builder" } }, "sensitive_attributes": [], "private": "bnVsbA==", "dependencies": [ "module.codebuild.data.aws_iam_policy_document.combined_permissions", "module.codebuild.data.aws_iam_policy_document.permissions", "module.codebuild.data.aws_iam_policy_document.vpc_permissions", "module.codebuild.data.aws_s3_bucket.secondary_artifact" ] } ] }, { "module": "module.codebuild", "mode": "managed", "type": "aws_iam_role", "name": "default", "provider": "provider[\"registry.terraform.io/hashicorp/aws\"]", "instances": [ { "index_key": 0, "schema_version": 0, "attributes": { "arn": "arn:aws:iam::259692501178:role/growi-official-image-builder", "assume_role_policy": "{\"Statement\":[{\"Action\":\"sts:AssumeRole\",\"Effect\":\"Allow\",\"Principal\":{\"Service\":\"codebuild.amazonaws.com\"},\"Sid\":\"\"}],\"Version\":\"2012-10-17\"}", "create_date": "2023-01-16T09:02:08Z", "description": "", "force_detach_policies": true, "id": "growi-official-image-builder", "inline_policy": [], "managed_policy_arns": [ "arn:aws:iam::259692501178:policy/service-role/CodeBuildBuildBatchPolicy-growi-official-image-builder-ap-northeast-1-growi-official-image-builder", "arn:aws:iam::259692501178:policy/service-role/growi-official-image-builder" ], "max_session_duration": 3600, "name": "growi-official-image-builder", "name_prefix": "", "path": "/", "permissions_boundary": null, "tags": { "Name": "growi-official-image-builder" }, "tags_all": { "Name": "growi-official-image-builder" }, "unique_id": "AROATY5XBDC5EIUMPRJKC" }, "sensitive_attributes": [], "private": "bnVsbA==", "dependencies": [ "module.codebuild.data.aws_iam_policy_document.role" ] } ] }, { "module": "module.codebuild", "mode": "managed", "type": "aws_iam_role_policy_attachment", "name": "default", "provider": "provider[\"registry.terraform.io/hashicorp/aws\"]", "instances": [ { "index_key": 0, "schema_version": 0, "attributes": { "id": "growi-official-image-builder-20230116090200654500000001", "policy_arn": "arn:aws:iam::259692501178:policy/service-role/growi-official-image-builder", "role": "growi-official-image-builder" }, "sensitive_attributes": [], "private": "bnVsbA==", "dependencies": [ "module.codebuild.aws_iam_policy.default", "module.codebuild.aws_iam_role.default", "module.codebuild.data.aws_iam_policy_document.combined_permissions", "module.codebuild.data.aws_iam_policy_document.permissions", "module.codebuild.data.aws_iam_policy_document.role", "module.codebuild.data.aws_iam_policy_document.vpc_permissions", "module.codebuild.data.aws_s3_bucket.secondary_artifact" ] } ] }, { "module": "module.codebuild", "mode": "managed", "type": "random_string", "name": "bucket_prefix", "provider": "provider[\"registry.terraform.io/hashicorp/random\"]", "instances": [ { "index_key": 0, "schema_version": 2, "attributes": { "id": "vpkowftojwbb", "keepers": null, "length": 12, "lower": true, "min_lower": 0, "min_numeric": 0, "min_special": 0, "min_upper": 0, "number": false, "numeric": false, "override_special": null, "result": "vpkowftojwbb", "special": false, "upper": false }, "sensitive_attributes": [] } ] } ], "check_results": null }