Sha256: dc8f42878599ee810b01bf93319267b38977680dda5f351c1baafb201441c01a

Contents?: true

Size: 718 Bytes

Versions: 11

Compression:

Stored size: 718 Bytes

Contents

resource "aws_iam_user" "ss" {
  name = "subspace"
  path = "/"

  tags = {
    Name = "Subspace IAM user"
    Environment = "Global"
  }
}

resource "aws_iam_access_key" "ss" {
  user = aws_iam_user.ss.name

  pgp_key = data.local_file.pgp_key.content_base64
}

resource "aws_iam_user_policy" "ss_s3" {
  name = "ss_s3_user_policy"
  user = aws_iam_user.ss.name

  policy = <<EOF
{
  "Version": "2012-10-17",
  "Statement": [
    {
      "Effect": "Allow",
      "Action": "s3:ListBucket",
      "Resource": "arn:aws:s3:::${local.state_bucket_name}"
    },
    {
      "Effect": "Allow",
      "Action": ["s3:GetObject", "s3:PutObject"],
      "Resource": "arn:aws:s3:::${local.state_bucket_name}/*"
    }
  ]
}
EOF
}

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
subspace-3.0.12 terraform/modules/s3_backend/iam_user.tf
subspace-3.0.11 terraform/modules/s3_backend/iam_user.tf
subspace-3.0.10 terraform/modules/s3_backend/iam_user.tf
subspace-3.0.9 terraform/modules/s3_backend/iam_user.tf
subspace-3.0.6 terraform/modules/s3_backend/iam_user.tf
subspace-3.0.5 terraform/modules/s3_backend/iam_user.tf
subspace-3.0.4 terraform/modules/s3_backend/iam_user.tf
subspace-3.0.3 terraform/modules/s3_backend/iam_user.tf
subspace-3.0.2 terraform/modules/s3_backend/iam_user.tf
subspace-3.0.0 terraform/modules/s3_backend/iam_user.tf
subspace-3.0.0.rc1 terraform/modules/s3_backend/iam_user.tf