Skip to content

Ranchman42/terraform-aws-kms-share-multi-accounts

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Forking Reason

There was a bug in this module that was preventing it from being used on any version of terraform above .14 so i forked it and fixed the issue.

Terraform-aws-kms-share-multi-accounts

module to create custom kms key and share access to multiple AWS accounts with option to add particular IAM Roles and Users

Sample way of using this module

There are 2 ways to use this module.

  1. Using default policy to create kms key and share to dest accounts
module "kms_sharing" {
  source           = "[email protected]:devops-made-easy/terraform-aws-kms-share-multi-accounts.git"
  version          = "1.0.0"
  key_name         = "devops-key-sharing"
  dest_account_ids = ["1111111", "222222", "333333"]
  dest_iam_roles   = ["arn:aws:iam::xxxxxx:role/dest_iam_role"](optional)
  src_account_ids  = ["444444"]
  src_iam_roles   = ["arn:aws:iam::xxxxxx:role/src_iam_role"](optional)
}
  1. Using Custom policy provided to this module
module "kms_sharing" {
  source           = "[email protected]:devops-made-easy/terraform-aws-kms-share-multi-accounts.git"
  version          = "1.0.0"
  key_name         = "devops-key-sharing"
  dest_account_ids = ["1111111", "222222", "333333"]
  dest_iam_roles   = ["arn:aws:iam::xxxxxx:role/dest_iam_role"](optional)
  src_account_ids  = ["444444"]
  src_iam_roles   = ["arn:aws:iam::xxxxxx:role/src_iam_role"](optional)
  user_policy      = file("${path.module}/xxxx.json.tpl")(optional)
}

Share the Love

Like this project? Please give it a ★ on our GitHub!(it helps us a lot)

About

Terraform module to create kms key and share access to multi accounts with IAM and Users

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • HCL 72.9%
  • Smarty 27.1%