IBM Cloud Docs
Setting up Terraform for Satellite

Setting up Terraform for Satellite

Terraform enables predictable and consistent creation of IBM Cloud services so that you can rapidly build complex, multi-tier cloud environments following Infrastructure as Code (IaC) principles. Similar to using the IBM Cloud CLI or API and SDKs, you can automate the creation, update, and deletion of your Satellite instances by using HashiCorp Configuration Language (HCL).

Looking for a managed Terraform on IBM Cloud® solution? Try out IBM Cloud® Schematics. With Schematics, you can use the Terraform scripting language that you are familiar with, but you don't have to worry about setting up and maintaining the Terraform command line and the IBM Cloud® Provider plug-in. Schematics also provides pre-defined Terraform templates that you can easily install from the IBM Cloud® catalog.

Installing Terraform and configuring resources for Satellite

Before you can create an authorization by using Terraform, make sure that you have completed the following tasks.

  • Make sure that you have the required access to create and work with Satellite resources.
  • Install the Terraform CLI and configure the IBM Cloud Provider plug-in for Terraform. For more information, see the tutorial for Getting started with Terraform on IBM Cloud®. The plug-in abstracts the IBM Cloud APIs that are used to complete this task.
  • Create a Terraform configuration file that is named main.tf. In this file, you define resources by using HashiCorp Configuration Language. For more information, see the Terraform documentation.
  • To create and manage the underlying infrastructure in other cloud providers, you must have the appropriate permissions. Review common permissions in other cloud providers.

Creating a Satellite location by using Terraform

Satellite provides Terraform templates for creating a Satellite location in the Satellite console.

You can clone and modify these Terraform templates from the Satellite Terraform GitHub repository.

For more information about creating a Satellite location by using Terraform, see ibm_satellite_location.

What's next?

Now that you successfully created your first Satellite location with Terraform on IBM Cloud, you can choose from the following tasks: