Skip to content

Terraform Directory Structure Refactoring #189

Open
@JinLee794

Description

@JinLee794

Refactor the Terraform deployment scenario such that the scenario-specific deployments can be managed through feature flags provided by .tfvars files.

Current Structure:

|-- scenarios/
|   |-- secure-baseline-ase/terraform/
|   |   |-- Parameters/uat.tfvars
|   |   |-- main.tf
|   |   `-- ...
|   `-- secure-baseline-multitenant/terraform`/
|       |-- Hub/
|       |   |-- Parameters/uat.tfvars
|       |   |-- main.tf
|       |   `-- ...
|       `-- Spoke/
|           |-- Parameters/uat.tfvars
|           |-- main.tf
|           `-- ... 

Proposed Structure:

|-- terraform/
|   |-- ase/
|   |   |-- main.tf
|   |   `-- ...
|   |-- hub/
|   |   |-- main.tf
|   |   `-- ...
|   |-- spoke/
|   |   |-- main.tf
|   |   `-- ...
|   |-- scenarios/
|   |   |-- ase.tfvars
|   |   |-- ase-multi-tenant.tfvars
|   |   `-- multi-tenant.tfvars
|   |-- main.tf -> references the hub/ spoke/ ase/ deployments via flags
|   `-- ...
|-- bicep/
|   `-- ...
`-- shared/
    |-- modules/
    |   |-- terraform/
    |   `-- bicep/
    `-- scripts/

Main benefit of this structure is that we can reuse the existing deployment files, but consolidate everything under a single deployment - which helps ensure consistent deployments with less repeated work.

Metadata

Metadata

Assignees

Type

No type

Projects

Status

In Progress

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions