Infrastructure management and user account permissions are critical for large teams, and automating these processes can mitigate security risks and enhance scalability. Infrastructure as Code, particularly with tools like HashiCorp Terraform, allows teams to efficiently manage cloud infrastructure using a declarative language, enabling modular and reusable configurations. Terraform's integration with Buildkite facilitates the management of CI/CD resources as code, ensuring consistency and reducing manual 'click-ops,' which can lead to errors and inconsistencies. The Buildkite Terraform provider, now officially supported, allows users to manage agent tokens, pipelines, and schedules, reinforcing best practices and streamlining infrastructure management. Elastic's CI team leverages Terraform and the Cloud Development Kit for Terraform (CDKTF) to automate project setups, including creating GitHub repositories and Buildkite pipelines, providing secure environments for Buildkite agents. This approach enables teams to utilize familiar programming languages and existing toolchains, enhancing their ability to handle infrastructure as code while allowing flexibility to overcome provider limitations.