Terraform
NetActuate provides an official Terraform provider that allows you to manage your infrastructure as code. You can provision virtual servers, configure networking, and manage resources using standard Terraform workflows.
Prerequisites
Getting Started
- Install the NetActuate Provider from the Terraform Registry.
- Configure authentication with your API key.
- Define your resources using the provider's resource types.
Quick Example
terraform {
required_providers {
netactuate = {
source = "netactuate/netactuate"
}
}
}
provider "netactuate" {
api_key = var.netactuate_api_key
}
resource "netactuate_server" "web" {
hostname = "web-01"
plan = "VR2x2x40"
location = "IAD3"
image = "5787"
ssh_keys = [var.ssh_key_id]
}
Note: Store your API key in a variable or environment variable. Do not hardcode it in your configuration files.
Control Node Setup
macOS
brew install terraform
Or use tfenv for version management:
brew install tfenv && tfenv install latest
Linux
# Via direct download (https://developer.hashicorp.com/terraform/install)
# Or via tfenv:
git clone https://github.com/tfutils/tfenv.git ~/.tfenv
echo 'export PATH="$HOME/.tfenv/bin:$PATH"' >> ~/.bashrc
tfenv install latest
Windows
winget install Hashicorp.Terraform
Or use WSL2 and follow the Linux instructions.
AI-Assisted Provisioning
All NetActuate Terraform repos include an AGENTS.md for AI coding assistants. See AI-Assisted Provisioning.
Reference Data
When writing Terraform configurations, you need identifiers for plans, locations, and images:
- API Virtual Server Plans -- Plan identifiers and naming conventions
- API Locations -- Available deployment locations
- API OS Images -- Operating system image identifiers
Documentation
| Page | Description |
|---|---|
| NetActuate Provider | Provider installation and authentication |
| Terraform Options | Resource and data source reference |
| Using the Terraform Registry | Installing the provider from the registry |
| Redundant BGP Sessions for Workers | Configuring BGP sessions via Terraform |
| Compute Node (IaaS) | Provisioning VMs with Terraform |
Note: The NetActuate Terraform provider is open source. Contributions and issue reports are welcome on GitHub.
Need Help?
If you need assistance with Terraform, visit our support page.