1 pointby souvlakius5 hours ago1 comment
  • souvlakius5 hours ago
    I built a live Terraform visualizer, but users wanted an AI to write and audit their HCL. Here’s how we did it without access to state or secrets

    Been writing TF since 0.11 and survived the 0.12 migration. Built multi-cloud architectures (AWS B2B banking, GCP peering, Crossplane self-service). After all this time Terraform never gets much easier, you just build more complicated headaches.

    Yes, Terraform is the `right` way of doing things. It allows you to review changes before applying but at the cost of being obscure. Most SWEs don't want to deal with it and even infra engineers will occasionally do some click-ops and then reconcile.

    Originally, I built a tool to auto-generate architecture diagrams from Terraform code, mostly because I hated having to manually update diagrams and expected other people did as well. After releasing it and talking to early users, I realised seeing the infrastructure was an issue but it wasn't the main issue. Changing it safely was. As an SRE, I really wanted to create a tool to help devs self-serve infrastructure and to speed up infra changes without having to add another abstraction layer on top. So, we created Grafos.ai and added an agentic layer to explain and modify the code, as well as a policy management system so you can define all of your organisation's policies, automatically run them against the changes, and also update your terraform to match them easily.

    We didn’t want to create an invasive and potentially destructive AI and give it to your infrastructure and we didn't want to break your development processes, so we built some ground rules into it.

    * Its doesn't do arbitrary code changes, it creates PRs so you can double check your terraform before anything is applied * Zero state or secret access, so you don’t have to trust it at all, it’s just your terraform code * Live visualisation so you can instantly see actually what changes are being proposed * Natural language guardrails and policies so you can make sure all changes are in line with your organisation's guardrails and style guides.

    I’d love for you to try it and tear it apart, it’s early days and we’re shipping features and changes literally everyday so any feedback good or bad would be amazing!