Stacks — IaC management
How to manage Infrastructure as Code at Scale Using Plural
Articles in this section:
The goal of Plural Stacks is to provide a scalable framework to manage infrastructure as code with a Kubernetes-friendly, API-driven approach. Stacks support Terraform, Terragrunt, Pulumi, Ansible, and custom runner workflows. The core workflow is as follows:
- Declaratively define a stack with a type (terraform, ansible, etc), a location in a git repository to source code from, and a cluster on which it will execute
- On each commit to the tracked git repository, a run is created which the Plural deployment operator will detect and execute on the targeted cluster
- this allows users to fine grain permissions and network location of IaC runs where both are necessary to configure.
- Plural will carefully execute the run for you, and besides basic information like communicating stdout to the UI, we will also gather and present useful information like inputs/outputs, terraform state diagrams and more
- On PRs to the tracked repository, a "plan" run is also executed and comments posted on the relevant PR where possible.
To get a better idea of the full power of the experience, feel free to take a look at this demo video (at 2x speed if you want to save some time):
Supported stack types
Type | Use it for |
|---|---|
TERRAFORM | Terraform configurations |
TERRAGRUNT | Terraform configurations orchestrated with Terragrunt |
PULUMI | Pulumi programs in supported runtimes |
ANSIBLE | Ansible playbooks |
CUSTOM | A custom runner image and command workflow |
Pulumi stacks use Pulumi's own state backends. See Pulumi stacks for Pulumi Cloud and self-managed backend authentication.
A Basic Stack
The most common way to instantiate a stack is via Kubernetes CRD. This gives a flexible, modular way to recreate infrastructure and pairs nicely with our PR Automation tooling for full self-service around IaC.
Here's an example: