Skip to content

Commit a60ba1d

Browse files
authored
[Updated] Terraform Provider Version (#7290)
1 parent 7340916 commit a60ba1d

File tree

9 files changed

+146
-125
lines changed
  • docs/guides/applications/configuration-management/terraform
    • create-a-multicloud-infrastructure-using-terraform
    • create-a-nodebalancer-with-terraform
    • create-terraform-module
    • deploy-a-wordpress-site-using-terraform-and-linode-stackscripts
    • how-to-build-your-infrastructure-using-terraform-and-linode
    • how-to-deploy-secure-linodes-using-cloud-firewalls-and-terraform
    • how-to-use-terraform-with-linode-object-storage
    • import-existing-infrastructure-to-terraform
    • secrets-management-with-terraform

9 files changed

+146
-125
lines changed

docs/guides/applications/configuration-management/terraform/create-a-multicloud-infrastructure-using-terraform/index.md

Lines changed: 41 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ description: 'This guide shows you how to use Multicloud Terraform to provide a
66
authors: ["Jeff Novotny"]
77
contributors: ["Jeff Novotny"]
88
published: 2021-04-23
9+
modified: 2025-06-18
910
keywords: ['Terraform','Linode','IaC','multicloud', 'automation', 'cloud manager']
1011
tags: ['terraform','ubuntu', 'ssh', 'security']
1112
license: '[CC BY-ND 4.0](https://creativecommons.org/licenses/by-nd/4.0)'
@@ -69,7 +70,7 @@ This guide is written for a non-root user. Commands that require elevated privil
6970

7071
## Downloading Terraform on your Linode Server
7172

72-
In this section, you install Terraform on an Ubuntu 20.04 Linode. These steps are generally applicable to most Debian-based distributions. You can use the Linode server as the hub for your Terraform-managed infrastructure, however, you can also install Terraform on your computer.
73+
In this section, you install Terraform on an Ubuntu 24.04 LTS Linode. These steps are generally applicable to most Debian-based distributions. You can use the Linode server as the hub for your Terraform-managed infrastructure, however, you can also install Terraform on your computer.
7374

7475
To download Terraform on a Linode server, follow the steps below:
7576

@@ -87,72 +88,68 @@ To download Terraform on a Linode server, follow the steps below:
8788
mkdir terraform
8889
cd terraform
8990

90-
1. Download Terraform using the `wget` command or from [Terraform's download page](https://www.terraform.io/downloads.html). This guide is written for the latest Terraform version 0.15.0 (at the time of writing this guide).
91+
1. Download Terraform using the `wget` command or from [Terraform's download page](https://www.terraform.io/downloads.html). This guide is written for Terraform version 1.12.2 (at the time of this writing).
9192

92-
wget https://releases.hashicorp.com/terraform/0.15.0/terraform_0.15.0_linux_amd64.zip
93+
wget https://releases.hashicorp.com/terraform/1.12.2/terraform_1.12.2_linux_amd64.zip
9394

94-
{{< note respectIndent=false >}}
95-
Previous versions of Terraform can be found on the [Terraform releases page](https://releases.hashicorp.com/terraform/).
96-
{{< /note >}}
95+
{{< note >}}
96+
See the [Terraform releases page](https://releases.hashicorp.com/terraform/) for release date and version information.
97+
{{< /note >}}
9798

98-
1. Download the `SHA256SUMS` file, and checksum `sig` file for the most recent version of Terraform (0.15.0 in this case).
99+
1. Download the `SHA256SUMS` file, and checksum `sig` file for the most recent version of Terraform (1.12.2 in this case).
99100

100101
- The SHA256 checksum file:
101102

102-
wget https://releases.hashicorp.com/terraform/0.15.0/terraform_0.15.0_SHA256SUMS
103+
wget https://releases.hashicorp.com/terraform/1.12.2/terraform_1.12.2_SHA256SUMS
103104

104105
- The checksum signature file:
105106

106-
wget https://releases.hashicorp.com/terraform/0.15.0/terraform_0.15.0_SHA256SUMS.sig
107+
wget https://releases.hashicorp.com/terraform/1.12.2/terraform_1.12.2_SHA256SUMS.sig
107108

108109
### Verify the Terraform Download
109110

110-
1. Locate HashiCorp's public GPG key on their [Security page](https://www.hashicorp.com/security) under the “Secure Communications” section. The key ID is `51852D87348FFC4C`.
111+
1. Locate HashiCorp's public GPG key on their [Security page](https://www.hashicorp.com/security) under the “Secure Communications” section. Replace `51852D87348FFC4C` with the current public key value.
111112

112113
gpg --recv-keys 51852D87348FFC4C
113114

114115
The following output confirms that the `gpg` key has been successfully imported.
115116

116117
{{< output >}}
117-
gpg: directory '/root/.gnupg' created
118-
gpg: keybox '/root/.gnupg/pubring.kbx' created
119118
gpg: /root/.gnupg/trustdb.gpg: trustdb created
120-
gpg: key 51852D87348FFC4C: public key "HashiCorp Security <[email protected]>" imported
119+
gpg: key 34365D9472D7468F: public key "HashiCorp Security (hashicorp.com/security) <[email protected]>" imported
121120
gpg: Total number processed: 1
122-
gpg: imported: 1
121+
gpg: imported: 1
123122
{{< /output >}}
124123

125124
1. Use `gpg` to validate the signature file. Use the exact names of the `sig` and `SHA256` files.
126125

127-
gpg --verify terraform_0.15.0_SHA256SUMS.sig terraform_0.15.0_SHA256SUMS
126+
gpg --verify terraform_1.12.2_SHA256SUMS.sig terraform_1.12.2_SHA256SUMS
128127

129128
The following output confirms that the `sig` file is a good signature from HashiCorp Security.
130129

131130
{{< output >}}
132-
gpg: Signature made Wed Apr 14 15:41:39 2021 UTC
133-
gpg: using RSA key 91A6E7F85D05C65630BEF18951852D87348FFC4C
134-
gpg: Good signature from "HashiCorp Security <[email protected]>" [unknown]
131+
gpg: Signature made Wed 11 Jun 2025 10:34:29 AM UTC
132+
gpg: using RSA key 374EC75B485913604A831CC7C820C6D5CD27AB87
133+
gpg: Good signature from "HashiCorp Security (hashicorp.com/security) <[email protected]>" [unknown]
135134
{{< /output >}}
136135

137136
1. Ensure the RSA key displayed in the output of the last step matches the fingerprint shown on the [Terraform Security page](https://www.hashicorp.com/security). The fingerprint is located in the same place as the GPG key in the "Secure Communications" section.
138137

139138
1. Verify the checksum of the `zip` archive. For the following command, use the exact name of the `SHA256SUMS` file.
140139

141-
sha256sum -c terraform_0.15.0_SHA256SUMS 2>&1 | grep OK
140+
sha256sum -c terraform_1.12.2_SHA256SUMS 2>&1 | grep OK
142141

143142
The `sha256sum` program displays the name of the `zip` file along with the status. If the status is **NOT** `OK`, then the `zip` file is corrupt and must be downloaded again.
144143

145144
{{< output >}}
146-
147-
terraform_0.15.0_linux_amd64.zip: OK
148-
149-
{{< /output >}}
145+
terraform_1.12.2_linux_amd64.zip: OK
146+
{{< /output >}}
150147

151148
### Installing and Configuring Terraform on the Linode Server
152149

153150
1. Unzip the `terraform_*_linux_amd64.zip` to your `terraform` directory.
154151

155-
unzip terraform_0.15.0_linux_amd64.zip
152+
unzip terraform_1.12.2_linux_amd64.zip
156153

157154
{{< note respectIndent=false >}}
158155
If you receive an error that indicates `unzip` is missing from your system, install the `unzip` package using the following command `sudo apt install unzip` and try again.
@@ -204,13 +201,19 @@ The following steps explain how you can construct a multicloud configuration con
204201

205202
1. At the top of the file, add a `terraform` block to define the [Linode Provider](https://registry.terraform.io/providers/linode/linode/latest/docs), followed by the declaration of the Linode provider itself. Within the provider block, add the `token` declaration. See Linode’s guide on [Getting Started with the Linode API](/docs/products/tools/api/get-started/#get-an-access-token) to learn how to create an API token, if you have not done so already.
206203

204+
{{< note title ="Linode Provider Version 3.0.0" >}}
205+
As of June, 2025, the Linode Terraform Provider version is 3.0.0. To determine the current version, see the [Linode Namespace](https://registry.terraform.io/namespaces/linode) in the Terraform Registry.
206+
207+
The Linode Terraform Provider version 3.0.0 requires `terraform` version 1.0 or greater. See [Terraform's developer documentation](https://developer.hashicorp.com/terraform/language/v1.1.x/upgrade-guides/1-0) for guidance on upgrading to version 1.0.
208+
{{< /note >}}
209+
207210
{{< file "~/terraform/linode-terraform.tf" >}}
208211

209212
terraform {
210213
required_providers {
211214
linode = {
212215
source = "linode/linode"
213-
version = "1.16.0"
216+
version = "3.0.0"
214217
}
215218
}
216219
}
@@ -227,7 +230,7 @@ provider "linode" {
227230
{{< file "~/terraform/linode-terraform.tf" >}}
228231

229232
resource "linode_instance" "terraform" {
230-
image = "linode/ubuntu20.04"
233+
image = "linode/ubuntu24.04"
231234
label = "Terraform-Example"
232235
group = "Terraform"
233236
region = "us-east"
@@ -247,7 +250,7 @@ terraform {
247250
required_providers {
248251
linode = {
249252
source = "linode/linode"
250-
version = "1.16.0"
253+
version = "3.0.0"
251254
}
252255
}
253256
}
@@ -259,7 +262,7 @@ provider "linode" {
259262
}
260263

261264
resource "linode_instance" "terraform" {
262-
image = "linode/ubuntu20.04"
265+
image = "linode/ubuntu24.04"
263266
label = "terraform-example"
264267
group = "terraform"
265268
region = "us-east"
@@ -390,12 +393,12 @@ This guide describes all three steps in detail.
390393

391394
{{< output >}}
392395

393-
* Finding linode/linode versions matching "1.16.0"...
396+
* Finding linode/linode versions matching "3.0.0"...
394397
* Finding latest version of hashicorp/aws...
395-
* Installing linode/linode v1.16.0...
396-
* Installed linode/linode v1.16.0 (signed by a HashiCorp partner, key ID F4E6BBD0EA4FE463)
397-
* Installing hashicorp/aws v3.34.0...
398-
* Installed hashicorp/aws v3.34.0 (signed by HashiCorp)
398+
* Installing linode/linode v3.0.0...
399+
* Installed linode/linode v3.0.0 (signed by a HashiCorp partner, key ID F4E6BBD0EA4FE463)
400+
* Installing hashicorp/aws v6.0.0...
401+
* Installed hashicorp/aws v6.0.0 (signed by HashiCorp)
399402
...
400403
Terraform has been successfully initialized!
401404

@@ -463,7 +466,7 @@ Terraform will perform the following actions:
463466
* boot_config_label = (known after apply)
464467
* group = "Terraform"
465468
* id = (known after apply)
466-
* image = "linode/ubuntu20.04"
469+
* image = "linode/ubuntu24.04"
467470
* ip_address = (known after apply)
468471
* ipv4 = (known after apply)
469472
* ipv6 = (known after apply)
@@ -522,7 +525,7 @@ linode_instance.terraform-web: Creating...
522525
backups_enabled: "" => "<computed>"
523526
boot_config_label: "" => "<computed>"
524527
group: "" => "Terraform"
525-
image: "" => "linode/ubuntu18.04"
528+
image: "" => "linode/ubuntu24.04"
526529
ip_address: "" => "<computed>"
527530
ipv4.#: "" => "<computed>"
528531
ipv6: "" => "<computed>"
@@ -557,12 +560,12 @@ Terraform can modify a resource without affecting the other elements of your inf
557560

558561
The following example illustrates how to simultaneously add a new Linode and change the AWS database table.
559562

560-
1. Edit the `linode-terraform.tf` file, and add the following snippet to the end of the file. This defines a 1GB Linode running Ubuntu 20.04 as a new resource.
563+
1. Edit the `linode-terraform.tf` file, and add the following snippet to the end of the file. This defines a 1GB Linode running Ubuntu 24.04 as a new resource.
561564

562565
{{< file "~/terraform/linode-terraform.tf" aconf >}}
563566
...
564567
resource "linode_instance" "terraform2-example" {
565-
image = "linode/ubuntu20.04"
568+
image = "linode/ubuntu24.04"
566569
label = "terraform-web-example-2"
567570
group = "terraform"
568571
region = "eu-west"
@@ -649,7 +652,7 @@ Terraform will perform the following actions:
649652
* boot_config_label = (known after apply)
650653
* group = "Terraform"
651654
* id = (known after apply)
652-
* image = "linode/ubuntu18.04"
655+
* image = "linode/ubuntu24.04"
653656
* ip_address = (known after apply)
654657
* ipv4 = (known after apply)
655658
* ipv6 = (known after apply)

docs/guides/applications/configuration-management/terraform/create-a-nodebalancer-with-terraform/index.md

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ description: 'This guide provides you with step-by-step instructions for install
55
authors: ["Linode"]
66
contributors: ["Linode"]
77
published: 2018-12-12
8-
modified: 2021-12-29
8+
modified: 2025-06-18
99
keywords: ['terraform','nodebalancer','node','balancer','provider','linode']
1010
license: '[CC BY-ND 4.0](https://creativecommons.org/licenses/by-nd/4.0)'
1111
image: CreateaNodeBalancerwitTerraform.png
@@ -32,10 +32,12 @@ If you would like to stop billing for the resources created in this guide, [remo
3232

3333
1. You should have Terraform installed in your development environment, and have a working knowledge of Terraform resource configuration and the [Linode provider](https://www.terraform.io/docs/providers/linode/index.html). For more information on how to install and use Terraform, check out our [Use Terraform to Provision Linode Environments](/docs/guides/how-to-build-your-infrastructure-using-terraform-and-linode/) guide.
3434

35-
{{< note respectIndent=false >}}
36-
[Terraform’s Linode Provider](https://github.com/terraform-providers/terraform-provider-linode) has been updated and now requires Terraform version 0.12+. To learn how to safely upgrade to Terraform version 0.12+, see [Terraform’s official documentation](https://www.terraform.io/upgrade-guides/0-12.html). View [Terraform v0.12’s changelog](https://github.com/hashicorp/terraform/blob/v0.12.0/CHANGELOG.md) for a full list of new features and version incompatibility notes.
35+
{{< note title ="Linode Provider Version 3.0.0" >}}
36+
As of June, 2025, the [Linode Terraform Provider](https://github.com/linode/terraform-provider-linode/) version is 3.0.0. To determine the current version, see the [Linode Namespace](https://registry.terraform.io/namespaces/linode) in the Terraform Registry.
37+
38+
The Linode Terraform Provider version 3.0.0 requires `terraform` version 1.0 or greater. See [Terraform's developer documentation](https://developer.hashicorp.com/terraform/language/v1.1.x/upgrade-guides/1-0) for guidance on upgrading to version 1.0.
3739

38-
The examples in this guide were written to be compatible with [Terraform version 0.11](https://www.terraform.io/docs/configuration-0-11/terraform.html) and will be updated in the near future.
40+
The examples in this guide were originally written to be compatible with [Terraform version 0.11](https://www.terraform.io/docs/configuration-0-11/terraform.html).
3941
{{< /note >}}
4042

4143
1. Terraform requires an API access token. Follow the [Getting Started with the Linode API](/docs/products/tools/api/get-started/#get-an-access-token) guide to obtain a token.
@@ -56,7 +58,7 @@ terraform {
5658
required_providers {
5759
linode = {
5860
source = "linode/linode"
59-
version = "1.16.0"
61+
version = "3.0.0"
6062
}
6163
}
6264
}
@@ -156,7 +158,7 @@ resource "linode_instance" "example-instance" {
156158
tags = ["nodebalancer-example"]
157159
region = var.region
158160
type = "g6-nanode-1"
159-
image = "linode/ubuntu18.10"
161+
image = "linode/ubuntu24.04"
160162
authorized_keys = [chomp(file(var.ssh_key))]
161163
root_pass = random_string.password.result
162164
private_ip = true

docs/guides/applications/configuration-management/terraform/create-terraform-module/index.md

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ description: 'This guide shows you how to create a Terraform module with nested
66
authors: ["Linode"]
77
contributors: ["Linode"]
88
published: 2018-12-12
9-
modified: 2021-06-01
9+
modified: 2025-06-18
1010
keywords: ['terraform','resource','modules','provider']
1111
tags: ["terraform"]
1212
license: '[CC BY-ND 4.0](https://creativecommons.org/licenses/by-nd/4.0)'
@@ -36,8 +36,10 @@ This guide covers the creation of a Terraform module used to deploy a Linode ins
3636

3737
1. Install Terraform on your local computer using the steps found in the **Install Terraform** section of the [Use Terraform to Provision Linode Environments](/docs/guides/how-to-build-your-infrastructure-using-terraform-and-linode/#install-terraform) guide. Your Terraform project directory should be named `linode_stackscripts`.
3838

39-
{{< note respectIndent=false >}}
40-
[Terraform’s Linode Provider](https://github.com/terraform-providers/terraform-provider-linode) has been updated and now requires Terraform version 0.12+. To learn how to safely upgrade to Terraform version 0.12+, see [Terraform’s official documentation](https://www.terraform.io/upgrade-guides/0-12.html). View [Terraform v0.12’s changelog](https://github.com/hashicorp/terraform/blob/v0.12.0/CHANGELOG.md) for a full list of new features and version incompatibility notes.
39+
{{< note title ="Linode Provider Version 3.0.0" >}}
40+
As of June, 2025, the [Linode Terraform Provider](https://github.com/linode/terraform-provider-linode/) version is 3.0.0. To determine the current version, see the [Linode Namespace](https://registry.terraform.io/namespaces/linode) in the Terraform Registry.
41+
42+
The Linode Terraform Provider version 3.0.0 requires `terraform` version 1.0 or greater. See [Terraform's developer documentation](https://developer.hashicorp.com/terraform/language/v1.1.x/upgrade-guides/1-0) for guidance on upgrading to version 1.0.
4143
{{< /note >}}
4244

4345
2. Terraform requires an API access token. Follow the [Getting Started with the Linode API](/docs/products/tools/api/get-started/#get-an-access-token) guide to obtain a token.
@@ -242,7 +244,7 @@ variable "stackscript_data" {
242244

243245
- Modules must include a description for each input variable to help document your configuration’s usage. This will make it easier for anyone else to use this module.
244246

245-
- Every variable can contain a default value. The default value is only used if no other value is provided. For example, if you have a favorite Linux distribution, you may want to provide it as your image variable’s default value. In this case, `linode/ubuntu18.04` is set as the default value.
247+
- Every variable can contain a default value. The default value is only used if no other value is provided. For example, if you have a preferred Linux distribution, you may want to provide it as your image variable’s default value. In this case, `linode/ubuntu18.04` is set as the default value.
246248

247249
- You can declare a `type` for each variable. If no `type` is provided, the variable will default to `type = "string"`.
248250

@@ -327,7 +329,7 @@ terraform {
327329
required_providers {
328330
linode = {
329331
source = "linode/linode"
330-
version = "1.16.0"
332+
version = "3.0.0"
331333
}
332334
}
333335
}

0 commit comments

Comments
 (0)