Skip to content

OT-CLOUD-KIT/terraform-aws-organizations-organizational-unit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Organization unit

Opstree Solutions
Opstree Solutions

This module helps users in setup:

  • Creation of organization units
  • Creating new AWS account

Prerequisites

  • AWS access of root account/management account of control tower with admin privilege
  • Terraform >= 1.3.0
  • AWS CLI

Providers

AWS

Inputs

Name Description Type Default Required
parent_id Parent id of the OUs under which new OUs will be created string null no
organization_unit_account_details About OUs name(as a key), new AWS account details such as email id, parent_id close_on_deletion map(object) null yes
create_organization_unit Whether you want to create OUs or not bool true no

Output

Name Description
org_unit_id OUs which has been created by TF

Usage

module "OUs" {
  source                            = "../"
  parent_id                         = "o-xxxxxxxx"
  organization_unit_account_details = var.organization_unit_account_details
}

variable "organization_unit_account_details" {
  type = map(object({
    organization_accounts = map(object({
      email_id          = string
      close_on_deletion = bool
      parent_id         = optional(string)
      tags              = optional(map(string))
    }))
  }))
  default = {
    "example" = {
      organization_accounts = {
        "account-1" = {
            email_id = "example@gmail.com"
            close_on_deletion = false
        }
      }
    }
  }
  description = "Variables of organization unit"
}

Contributor

Ashutosh Yadav

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •  

Languages