Azion Terraform Provider

Terraform is an infrastructure as code tool that makes it possible to manage your infrastructure efficiently through code. The files created to manage your infrastructure can be reused, versioned, and shared, helping you to have a consistent workflow to provision and manage all of your infrastructure throughout its lifecycle.


How does Azion Terraform Provider work?

Terraform works based on providers. A provider is in charge of managing the lifecycle of a particular resource type. They’re implemented as plugins, which are separate executable code files that may be loaded into Terraform at runtime.

Azion Terraform Provider is an open source project, registered in Terraform Registry that uses the Azion SDK (Go) to communicate with the Azion APIs, so you can manage your infrastructure hosted on the Azion platform, locally, as code.


Process

Azion Terraform Provider Process

Terraform Core: it communicates with the Azion Terraform Provider.

Note: you must have Terraform Core installed in your environment. See how to install it.

Azion Terraform Provider: built in Go, it communicates with the Azion SDK (Go).

Azion SDK (Go): it communicates with the Azion APIs.


First steps

In your .tf file, you must set the Azion Terraform Provider as the provider and set its version as well, such as:

required_providers {
source = "aziontech/azion"
version = "1.x.y" // it depends on the version you're willing to use.
}

With the provider configured, it’s recommended to configure a personal token:

provider "azion" {
api_token = "token" // Here you place your personal token
}

Note: if the personal token isn’t provided as presented above, a prompt will ask you to inform it when you try to run any Terraform command.

After these steps, you’re ready to get started managing your infrastructure using the Azion Terraform Provider.

Here’s how your .tf should look like at this point:

required_providers {
source = "aziontech/azion"
version = "1.x.y" // it depends on the version you're willing to use.
}
provider "azion" {
api_token = "token" // Here you place your personal token
}

Implementation


Contributors