37 lines
832 B
Terraform
37 lines
832 B
Terraform
|
|
data "template_file" "policy_a" {
|
||
|
|
template = file("../../templates/role_a_policy.tpl")
|
||
|
|
}
|
||
|
|
|
||
|
|
data "template_file" "asume_role_policy" {
|
||
|
|
template = file("../../templates/asume_role_policy.tpl")
|
||
|
|
vars = {
|
||
|
|
prod_account_id = var.prod_account_id
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
data "template_file" "asume_role" {
|
||
|
|
template = file("../../templates/assume_role.tpl")
|
||
|
|
}
|
||
|
|
|
||
|
|
|
||
|
|
data "terraform_remote_state" "group_2" {
|
||
|
|
backend = "s3"
|
||
|
|
|
||
|
|
config = {
|
||
|
|
bucket = "mytesting-tf-states"
|
||
|
|
profile = "terra"
|
||
|
|
region = "eu-west-1"
|
||
|
|
key = "000000000000/iam/users_and_groups/normal_users/terraform.tfstate"
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
data "terraform_remote_state" "group_1" {
|
||
|
|
backend = "s3"
|
||
|
|
|
||
|
|
config = {
|
||
|
|
bucket = "mytesting-tf-states"
|
||
|
|
profile = "terra"
|
||
|
|
region = "eu-west-1"
|
||
|
|
key = "000000000000/iam/users_and_groups/cli_users/terraform.tfstate"
|
||
|
|
}
|
||
|
|
}
|