# Terraform

{% hint style="danger" %}

### <mark style="color:red;">**The BastionZero product is maintained for existing BastionZero customers only.**</mark>&#x20;

Moving forward, we are natively rebuilding BastionZero’s technology as Cloudflare’s [Access for Infrastructure](https://developers.cloudflare.com/cloudflare-one/applications/non-http/infrastructure-apps/) service.
{% endhint %}

{% hint style="info" %}
[BastionZero's Terraform provider can be found here. ](https://registry.terraform.io/providers/bastionzero/bastionzero/latest/docs)
{% endhint %}

## What is Terraform?

Terraform is an open-source infrastructure-as-code (IaC) tool developed by HashiCorp, designed to provision and manage cloud infrastructure, on-premises resources, and various service providers using a declarative language. It enables developers and operations teams to create, modify, and manage resources in an organized and efficient manner, allowing for version control, collaboration, and automation.&#x20;

## Benefits of using Terraform with BastionZero

1. Unified Configuration Management

Terraform allows you to define your infrastructure using human-readable, declarative configuration files. By managing BastionZero's access control policies with Terraform, you can administer both your cloud infrastructure and access control policies in a unified manner. This simplifies the process of maintaining your environment and ensures consistency across your infrastructure and access control settings.

2. Version Control and Collaboration

With Terraform, you can version, reuse, and share your configuration files, making it easier to track changes and collaborate with your team. When managing BastionZero's access control policies, you can keep a clear history of modifications, roll back to previous configurations if necessary, and establish a streamlined workflow for your team to follow.

3. Templating & Modular Infrastructure Management

Terraform supports the use of modules, allowing you to group and reuse infrastructure components in a modular fashion. This modular approach can be applied to BastionZero's access control policies, enabling you to create reusable access control templates for different environments or project requirements. This not only reduces configuration complexity but also promotes best practices and standardization across your organization.

4. Improved Security and Compliance

When managing BastionZero's access control with Terraform, you can leverage its state management capabilities to track the current state of your infrastructure and access control settings. This provides a clear overview of your environment, enabling you to detect and remediate any discrepancies or misconfigurations promptly. Moreover, Terraform's declarative language makes it easier to enforce access control policies and adhere to security and compliance requirements.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.bastionzero.com/docs/automation-and-integrations/terraform.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
