Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kops - Create S3 bucket for hosting CI results #6950

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions infra/aws/terraform/kops-infra-ci/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -76,3 +76,34 @@ resource "aws_s3_bucket_acl" "kops_oidc_store" {
bucket = aws_s3_bucket.kops_oidc_store.id
acl = "public-read"
}

## Used by kOps for hosting CI build artifacts and version markers
resource "aws_s3_bucket" "kops_ci_results" {
provider = aws.kops-infra-ci
bucket = "k8s-infra-kops-ci-results"
tags = var.tags
}

resource "aws_s3_bucket_ownership_controls" "kops_ci_results" {
provider = aws.kops-infra-ci
bucket = aws_s3_bucket.kops_ci_results.id
rule {
object_ownership = "BucketOwnerPreferred"
}
}

resource "aws_s3_bucket_public_access_block" "kops_ci_results" {
provider = aws.kops-infra-ci
bucket = aws_s3_bucket.kops_ci_results.id

block_public_acls = false
block_public_policy = false
ignore_public_acls = false
restrict_public_buckets = false
}

resource "aws_s3_bucket_acl" "kops_ci_results" {
provider = aws.kops-infra-ci
bucket = aws_s3_bucket.kops_ci_results.id
acl = "public-read"
}