0035: Programmatic Organizational Structure Management via AWS CDK
STATUS
Request for comments
CONTEXT
Managing organizational structure (users and groups) for the tech team in AWS Identity Center has historically been a manual process, leading to inconsistencies, lack of visibility, and challenges in auditing or replicating changes. As our team grows and our compliance requirements increase, it is critical to have a version-controlled, programmatically accessible way to manage these resources. This will improve traceability, enable peer review, and allow for automated provisioning and updates.
Considered Options
- Continue manual management of users and groups in AWS Console
- Would also mean continual mananual definitions of those users and groups in our code.
- Use third-party identity management tools
- Manage users and groups programmatically via AWS CDK (Identity Center constructs)
DECISION
We will adopt AWS CDK to define and manage our tech team's organizational structure, specifically users and groups in AWS Identity Center. All changes to users, groups, and their relationships will be made through CDK code, stored in version control, and deployed via our standard infrastructure pipelines. This approach ensures that our org structure is reproducible, auditable, and can be peer-reviewed like any other code change.
Manual changes in the AWS Console will be strongly discouraged and even locked-down, and, where possible, monitored or reverted to maintain alignment with the CDK source of truth. We will need to figure out a way to use the users and groups defined in this project in GitHub too.
CONSEQUENCES
Positive outcomes:
- Organizational structure is version-controlled and auditable.
- Enables code review and approval workflows for org changes.
- Reduces risk of configuration drift and manual errors.
- Facilitates onboarding/offboarding and group membership changes via automation.
Negative outcomes:
- Initial migration effort to codify existing users/groups.
- Requires team familiarity with AWS CDK and pipeline processes.
- Potential for deployment errors if not carefully reviewed.
Risks
- Accidental removal or misconfiguration of users/groups during migration or updates.
- We should get a list of old and new teams and make a checklist of which ones to remove and which ones to keep to further help facilitate this migration.
- Pipeline or CDK errors could impact access if not properly tested.
- Which tests should we create to enable more trust in this feature?
- Reliance on AWS CDK features for Identity Center, which may evolve over time.
NOTES
Implementation Plan
The implementation will follow a structured approach using AWS CDK with the following components:
Repository Structure
- Create new repository:
aws-identity-center-org-structure-cdk-app - Implement CDK App:
aws-identity-center-org-structure-cdk-app
Stack Architecture
The CDK application will be organized into the following stacks:
organizationStack - AWS Organizations management- Register delegated administrator account for organization structure management
-
Enable necessary AWS services
-
engineersStack - Identity Center user management -
Manage all Identity Center users programmatically
-
teamsStack - Identity Center group management -
Manage all Identity Center groups programmatically
-
organizational-structureStack - AWS Organizations OU management -
Manage organizational units (OUs) programmatically
-
accountsStack - AWS Organizations account management - Manage AWS accounts programmatically
Deployment Strategy
- Deploy all stacks initially, even if empty
- Import existing resources into their respective stacks using CDK Import tool
- Establish CDK as the single source of truth for organizational structure
Future Considerations
- Remove unused IAM Users and User Groups
- Ensure Identity Center groups, users, and accounts align with current organizational structure
- Integrate with GitHub for user and group synchronization
References
- AWS CDK Documentation
- AWS Identity Center (successor to AWS SSO)
- adr.github.io
- Org Chart
- Team Organization Chart
- Mission Aligned Teams Chart
- Team Topologies
- PR #61: docs: add tech organization management cdk app and account
- PR #127: docs: backfill PR reference links for existing ADRs
Original Author
- Dakota Washok