Config sets

You use config sets to specify which CloudFormation stacks you want to deploy to your organization's member accounts.

Config set directory and files

Config sets are standard Takomo stack configurations‚ but instead of the stacks directory, you put them to subdirectories under the config-sets directory. The directory names become the names of the config sets, and you use them to refer to the config sets in the organization configuration file. You place your stack group and stack configuration files directly in the config set directory's root. Other Takomo directories such as the templates directory remains in the project's root.

Example

Here is an example with two config sets named common and network.

.
├─ templates                
├─ config-sets
│  ├─ common                # config set named 'common'
│  │  ├─ budgets.yml
│  │  └─ cloudtrail.yml
│  └─ network               # config set named 'network'
│     ├─ config.yml
│     └─ vpc.yml 
└─ organization
   └─ organization.yml

The common config set has two stacks: budgets.yml and cloudtrail.yml. The network config set has vpc.yml stack and a stack group configuration file config.yml.

Attaching config sets

You can attach config sets to organizational units or accounts. Organizational units and accounts inherit config sets from the organizational unit they belong to. They can add config sets of their own but can't remove the config sets they inherited. You attach config sets to organizational units and accounts by providing single config set name or a list of config set names in their configSets property.

Example

Let's continue the organization configuration we started in the previous chapters and see how to attach our config sets to accounts.

We attached the common config set to the Root organizational unit which attaches it to all OUs and accounts that are located under the Root OU. We chose a different approach with the networking config set and attached it directly to account 876754648373.

Account admin role

When you deploy config sets to your accounts, Takomo assumes an IAM role from each account and uses it to execute the deployment. By default, Takomo attempts to assume a role named OrganizationAccountAccessRole, but you can change the role by providing a different role name in accountAdminRoleName property. This property can be used at the top-level of organization configuration, in organizational units, and in accounts.

Example

This is how you specify the account admin role.

Last updated

Was this helpful?