Using a Python Script as an External Data Source for Terraform

Terraform is an incredibly powerful infrastructure-as-code (IaC) tool that allows you to easily define, deploy and manage your application infrastructure across many providers. An example being that you may want to spin up an AWS EC2 instance, or create and manage lambda functions. One of the many abilities of terraform is the possibility to use dynamic data sources for the Terraform modules, allowing for the running scripts (in our case a python script) and using its output to drive the Terraform configuration....

January 5, 2023 · 3 min · Matt Ellis