Encore compared to Terraform / Pulumi

Helping you avoid the pitfalls of infrastructure as code

There are many tools designed to overcome the challenges of cloud infrastructure complexity. Terraform and Pulumi are infrastructure as code tools that help you provision infrastructure by writing infrastructure configuration files. Encore uses a fundamentally different approach, let's take a look at how they compare.

EncoreTerraformPulumi
Approach?Infrastructure from CodeInfrastructure as CodeInfrastructure as Code
Supports all major cloud providers?YesYesYes
Write configuration files?NeverAlwaysAlways
Uses custom DSL?NoYesNo
Separate codebase for infra config?NoYesYes
Continuous effort required to keep environments in sync?NeverAlwaysAlways
Preview Environments?Built-inBig investmentBig investment
Automatic Distributed Tracing?YesNoNo

Drawbacks of Infrastructure as Code

A challenge with Infrastructure as Code, aside from being a lot of manual labor, is that you end up with a separate codebase to maintain and keep in sync with your application's actual requirements. The complexity and scope of this problem grows as you introduce development and test environments.

What's worse is, infrastructure as code does very little to help you cope with evolving infrastructure requirements. You still need to manually write new infrastructure configuration files, and refactor your application to function with the new infrastructure.

Encore's infrastructure from code approach means there are no configuration files to maintain, nor any refactoring to do when changing the underlying infrastructure. Your application code is the source of truth for the logical infrastructure requirements!

In practise, you use Encore's Infrastructure SDK to declare your infrastructure needs as part of your application code, and Encore automatically provisions the necessary infrastructure in all types of environments and across all major cloud providers. (This means your application is cloud-agnostic by default.)