Skip to content
Navigation Menu

IBM Cloud

  • CatalogCatalog
  • Cost EstimatorCost Estimator
    • HelpHelp
      • Docs
  • Log in
  • Sign up
  • Catalog
  • Cost Estimator
  • Help
    • Docs

  • Navigation settings

Error

Change theme

This feature is in early stage, some parts of the platform might not fully support different themes yet.

Themes
  1. Catalog

Resource group module

Looks up or creates an IBM Cloud resource group by name

  • Date of last update: 05/26/2025
  • Docs
  • Readme file
warning icon
This product is deprecated
Resource group module will not be available after 08/24/2025. You can install the product until then.

Module overview

This module returns the ID for the name of a resource group. It can also create a group from a name and return the ID.

Usage

Create new Resource group:

module "resource_group" {
  # Replace "X.X.X" with a release version to lock into a specific release
  source              = "https://cm.globalcatalog.cloud.ibm.com/api/v1-beta/offering/source?archive=tgz&kind=terraform&name=terraform-ibm-resource-group&version=X.X.X"
  resource_group_name = "new-resource-group"
}

Return ID of an existing Resource group:

module "resource_group" {
  # Replace "X.X.X" with a release version to lock into a specific release
  source                       = "https://cm.globalcatalog.cloud.ibm.com/api/v1-beta/offering/source?archive=tgz&kind=terraform&name=terraform-ibm-resource-group&version=X.X.X"
  existing_resource_group_name = "existing-resource-group"
}

Features and capabilities

Create an IBM Cloud resource group

Create an IBM Cloud resource group and return the ID.

Return the ID of an IBM Cloud resource group

Pass in the name of an IBM Cloud resource group. The module returns the ID of the group.

    Version last updated: 11/17/2023
    Example

      Details

      • Docs
      • Content source 

      Details

      Type
      • Terraform
      Provider
      • Community
      Category
      • Developer tools
      Last updated
      • 05/26/2025
      Product version
      • v1.1.4
      Example
      • Existing resource group
      Copy
      Copy
      Copy
      Copy
      Copy
      Copy

      Current weekly downloads

      Count: 0

      Existing resource group example

      An example showing how the module can take in an existing Resource group name, and return the Resource group ID as an output.

      Existing resource group example

      Focus sentinel
      Close

      Existing resource group example

      Focus sentinel

      An example that shows how the module can take in an existing resource group name and return the resource group ID as an output.

      Follow these steps to download the code and configure it. Then, run the example on your local machine. Learn more.
      1. Download the source file for this example, and then extract the .tar.gz file.
      2. Change to the extracted
        Copy to clipboard
        directory.
      3. If any module in the example comes from a private catalog, run the
        Copy to clipboard
        CLI command as a user who has account access to the private catalog.
      4. Run the following Terraform commands in the same terminal instance.
        $ terraform init
        Copy to clipboard
        $ terraform plan
        Copy to clipboard
        $ terraform apply
        Copy to clipboard