The declarative programming paradigm, which focuses on describing what you want to achieve rather than how to achieve it, is rapidly becoming the standard for managing complex systems. From infrastructure and databases to even diagramming, the declarative approach offers a more predictable, maintainable, and automated way to work. This shift is empowering developers to manage complexity with greater confidence and ease.
This month, we highlight five projects that exemplify the power and versatility of the declarative approach:
D2 | Declarative diagramming as code |
pgschema | Terraform-style schema migration for Postgres |
Terraform | The original declarative infrastructure as code |
OpenTofu | The community's open-source Terraform |
Pulumi | Infrastructure as real code |
D2 is a modern diagram scripting language that turns text into diagrams. It allows you to create complex, high-quality diagrams using a simple, declarative syntax. Instead of manually drawing boxes and lines, you describe the components of your system and their relationships, and D2 handles the layout and rendering.
👉 D2 is making "diagrams as code" a practical reality, enabling developers to version, review, and share diagrams alongside their code.
pgschema brings the popular Terraform-style declarative workflow to PostgreSQL schema management. Instead of writing imperative migration scripts (e.g., ALTER TABLE ...
), you declare the desired state of your schema in a file. pgschema then generates and applies the necessary changes to get your database to that state.
👉 pgschema simplifies database schema management by making it as easy and reliable as managing infrastructure with Terraform.
Terraform is the tool that popularized the concept of declarative infrastructure as code (IaC). It allows you to define and provision infrastructure across a wide range of cloud providers using a high-level configuration language called HCL. For years, it has been the de facto standard for IaC.
👉 Terraform remains the established giant in the IaC space, but its license change has opened the door for new challengers.
OpenTofu is a community-driven, open-source fork of Terraform created in response to HashiCorp's license change. Hosted by the Linux Foundation, it aims to keep Terraform truly open source (under the MPL-2.0 license) and is managed by a community of developers and organizations. It serves as a drop-in replacement for Terraform.
👉 OpenTofu is a powerful testament to the open-source community's ability to rally and preserve access to critical tools.
Pulumi offers a unique take on declarative infrastructure by allowing you to use general-purpose programming languages like Python, TypeScript, Go, and C# to define your infrastructure. This means you can leverage familiar tools, concepts, and libraries—like loops, functions, and classes—to build and manage your cloud resources.
👉 Pulumi bridges the gap between infrastructure and software development, empowering teams to manage infrastructure with the same tools and practices they use for their applications.
✨ That's October: five projects that showcase the power and breadth of the declarative revolution. By focusing on the "what" instead of the "how," these tools are making it easier than ever to build, manage, and scale complex systems with confidence.