3 ms·
Infrastructure from code is great, when your CI system generates the production diff and adds it to the code review. Then it's clear exactly what will get dele
by mleonhard 4y ago
Infrastructure from code is great, when your CI system generates the production diff and adds it to the code review. Then it's clear exactly what will get deleted. The deployment process also needs to be restartable and steps skippable. So for example, when a migration fails, you can perform it manually, re-deploy and skip the broken step. So far, no infrastructure-as-code tool works like this.
I know of only two tools that work effectively: Terraform & Pulumi. Terraform's config language has major flaws and Hashicorp is not interested in fixing them. For example, one cannot use a single Terraform config to create a database instance and a database inside it, or a VM and a server inside it, etc. So every application requires multi-stage configs which are full of footguns. Pulumi supports proper languages like Python & Golang and does not have this problem.
I would like to see a Rust version of Pulumi that uses static typing to eliminate run-time errors in infrastructure config. Maybe Shuttle will become that? It looks like they're integrating the web server with the infrastructure code. I think they should go in the opposite direction and make everything modular (usable separately) and composable. I want to write `deploy.rs` and run `cargo deploy`.
- inferiorhuman 4y ago> Pulumi supports proper languages like Python & Golang and does not have this problem. Having battled with Chef I can say with quite a bit of vim and vigor: noooooo. Everybody loves the idea of having a Turing complete language at their disposal until they manage to blow both their feet off one toe at a time. I was going to say that Hashicorp made the deliberate design choice to avoid putting a bunch of conditional logic into HCL. However: https://www.terraform.io/cdktf https://www.terraform.io/cdktf