Atmos Go Templates

•
1.3k
•

Optimizes infrastructure orchestration by applying advanced Go templates with Sprig and Gomplate functions to Atmos stack configurations.

The Atmos Go Templates skill empowers DevOps engineers to maintain DRY (Don't Repeat Yourself) infrastructure by providing a robust templating engine for Atmos. It extends standard Go text/template syntax with the powerful Sprig and Gomplate libraries, enabling complex conditional logic, loops, and dynamic key generation that go beyond standard YAML capabilities. By leveraging built-in functions like atmos.Component and atmos.GomplateDatasource, it allows for seamless data fetching from remote Terraform states, external APIs, and secret stores, streamlining the orchestration of Terraform and Helmfile deployments.

Key Features

01Dynamic external data fetching with atmos.GomplateDatasource caching
02Cross-component attribute and output retrieval via atmos.Component
03Multi-pass template evaluation for complex configuration pipelines
04Full Sprig and Gomplate function library integration
051,291 GitHub stars
06Access to comprehensive Atmos context variables including stacks and workspaces

Use Cases

01Generating dynamic cloud resource tags and metadata based on stack context
02Injecting real-time data from external APIs or secrets into infrastructure manifests
03Resolving inter-component dependencies by fetching remote state outputs