Skip to content

Commit 5d45051

Browse files
committed
Forgot to remove a couple resources that were moved to iam.tf
1 parent b01913f commit 5d45051

File tree

1 file changed

+1
-28
lines changed
  • terraform/modules/environment

1 file changed

+1
-28
lines changed

terraform/modules/environment/main.tf

Lines changed: 1 addition & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -17,36 +17,9 @@ module "vpc" {
1717
kubernetes_cluster_name = local.kubernetes_cluster_name
1818
}
1919

20-
# Data sources for EKS IAM
20+
# To get the current account id
2121
data "aws_caller_identity" "current" {}
2222

23-
# Use this role to limit access to the k8s admin serviceaccount
24-
data "aws_iam_policy_document" "assumerole_root_policy" {
25-
statement {
26-
actions = ["sts:AssumeRole"]
27-
28-
principals {
29-
type = "AWS"
30-
identifiers = ["arn:aws:iam::${data.aws_caller_identity.current.account_id}:root"]
31-
}
32-
}
33-
34-
# Allow the CI user to assume this role
35-
statement {
36-
actions = ["sts:AssumeRole"]
37-
38-
principals {
39-
type = "AWS"
40-
identifiers = [data.aws_iam_user.ci_user.arn]
41-
}
42-
}
43-
}
44-
45-
resource "aws_iam_user_policy_attachment" "circleci_ecr_access" {
46-
user = data.aws_iam_user.ci_user.user_name
47-
policy_arn = "arn:aws:iam::aws:policy/AmazonEC2ContainerRegistryPowerUser"
48-
}
49-
5023
#
5124
# Provision the EKS cluster
5225
module "eks" {

0 commit comments

Comments
 (0)