Some checks are pending
Build juntekim.com / Push-to-juntekim-to-docker-hub (push) Waiting to run
Build juntekim.com / run-on-k8s (push) Blocked by required conditions
Build & Deploy stripe-to-invoice (with DB secrets + migrations) / build (push) Waiting to run
Build & Deploy stripe-to-invoice (with DB secrets + migrations) / Deploy Postgres (PV + PVC + Deployment) (push) Blocked by required conditions
Build & Deploy stripe-to-invoice (with DB secrets + migrations) / Apply runtime secrets (push) Blocked by required conditions
Build & Deploy stripe-to-invoice (with DB secrets + migrations) / Run DB migrations (Atlas) (push) Blocked by required conditions
Build & Deploy stripe-to-invoice (with DB secrets + migrations) / deploy (push) Blocked by required conditions
Terraform Plan / Terraform Plan (pull_request) Waiting to run
39 lines
811 B
HCL
39 lines
811 B
HCL
module "bucket" {
|
|
source = "../s3_bucket"
|
|
|
|
bucket_name = var.bucket_name
|
|
versioning_enabled = true
|
|
retention_days = 90
|
|
}
|
|
|
|
resource "aws_iam_user" "databasus_backup" {
|
|
name = "databasus-backup"
|
|
}
|
|
|
|
resource "aws_iam_access_key" "databasus_backup" {
|
|
user = aws_iam_user.databasus_backup.name
|
|
}
|
|
|
|
resource "aws_iam_user_policy" "databasus_backup" {
|
|
name = "databasus-backup-s3"
|
|
user = aws_iam_user.databasus_backup.name
|
|
|
|
policy = jsonencode({
|
|
Version = "2012-10-17"
|
|
Statement = [
|
|
{
|
|
Effect = "Allow"
|
|
Action = [
|
|
"s3:PutObject",
|
|
"s3:GetObject",
|
|
"s3:DeleteObject",
|
|
"s3:ListBucket"
|
|
]
|
|
Resource = [
|
|
module.bucket.bucket_arn,
|
|
"${module.bucket.bucket_arn}/*"
|
|
]
|
|
}
|
|
]
|
|
})
|
|
}
|