A Terraform provider for managing TrueNAS SCALE and Community editions.
Installation
terraform {
required_providers {
truenas = {
source = "deevus/truenas"
version = "~> 0.1"
}
}
}
Usage
provider "truenas" {
host = "192.168.1.100"
auth_method = "ssh"
ssh {
user = "terraform"
private_key = file("~/.ssh/terraform_ed25519")
}
}
# Create a dataset
resource "truenas_dataset" "example" {
pool = "tank"
name = "example"
}
Features
- Data Sources: Query pools and datasets
- Resources: Manage datasets, host paths, files, and applications
Documentation
Full documentation is available on the Terraform Registry.
Requirements
- TrueNAS SCALE or TrueNAS Community
- SSH access with a user configured for
midclt (see User Setup)
License
MIT License - see LICENSE for details.