IBM Cloud Docs
Embedding software in Terraform

Embedding software in Terraform

Instead of deploying the product on IBM Cloud®, you can copy and embed the product's code into your own Terraform configuration. This task is for users who are experienced with Terraform.

Before you begin

  1. Install the IBM Cloud CLI.
  2. Install the Catalog Management CLI plug-in.
  3. Ensure that you have a Terraform environment on your local machine.

Running locally in a Terraform template

  1. Log in to the IBM Cloud CLI.

  2. Copy the code from the IBM Cloud catalog.

  3. Embed the code in your Terraform template, and set the values for your configuration.

  4. Run the ibmcloud catalog netrc command to configure a .netrc file with an authentication token.

    You might need to configure the IBM Cloud provider. For more information, see the IBM Cloud Provider docs.

  5. Run the terraform init command to download all of the required Terraform modules.

  6. Run the terraform plan command to see what resources will be created.

  7. Run the terraform apply command to create the resources. It might take some time to create the resources.