Skip to content

Latest commit

 

History

History
128 lines (102 loc) · 5.95 KB

README.md

File metadata and controls

128 lines (102 loc) · 5.95 KB

IBM Dedicated Host Module

Stable (With quality checks) latest release pre-commit Renovate enabled semantic-release

This module used to provision dedicated Host which is a fully dedicated, single-tenant physical server hosted in IBM Cloud data centers. It is designed for enterprises that require strict isolation of workloads, enhanced security, and consistent performance. With a dedicated host, customers have full control over server allocation, resource usage, and compliance requirements while leveraging the scalability and reliability of the IBM Cloud.

Overview

terraform-ibm-dedicated-host

Usage

terraform {
  required_version = ">= 1.9.0"
  required_providers {
    ibm = {
      source  = "IBM-Cloud/ibm"
      version = ">= 1.71.2, < 2.0.0"
    }
  }
}

locals {
    region = "us-south"
}

provider "ibm" {
  ibmcloud_api_key = "XXXXXXXXXX"  # replace with apikey value
  region           = local.region
}

module "dedicated_host" {
  source            = "terraform-ibm-modules/dedicated-host/ibm"
  version           = "X.X.X" # Replace "X.X.X" with a release version to lock into a specific release
  prefix = "dhtest"
  dedicated_hosts = [
    {
      host_group_name     = "${var.prefix}-dhgroup"
      existing_host_group = false
      resource_group_id   = module.resource_group.resource_group_id
      class               = "bx2"
      family              = "balanced"
      zone                = "${var.region}-1"
      resource_tags       = var.resource_tags
      dedicated_host = [
        {
          name    = "${var.prefix}-dhhost"
          profile = "bx2-host-152x608"
        }
      ]
    }
  ]
}

Required IAM access policies

You need the following permissions to run this module.

  • Account Management
    • Resource Group service
      • Viewer platform access
  • IAM Services
    • IBM Cloud Activity Tracker service
      • Editor platform access
      • Manager service access
    • IBM Cloud Monitoring service
      • Editor platform access
      • Manager service access
    • IBM Cloud Object Storage service
      • Editor platform access
      • Manager service access

Requirements

Name Version
terraform >= 1.9.0
ibm >= 1.71.2, < 2.0.0

Modules

No modules.

Resources

Name Type
ibm_is_dedicated_host.dh_host resource
ibm_is_dedicated_host_group.dh_group resource
ibm_is_dedicated_host_group.existing_dh_group data source

Inputs

Name Description Type Default Required
dedicated_hosts A list of objects which contain the required inputs for the dedicated host and dedicated host groups, a flag indicating the user to use an existing host group by enabling it. Also has the default values for a dedicated host setup which are recommended by IBM Cloud.
list(object({
host_group_name = string
existing_host_group = optional(bool, false)
resource_group_id = string
class = optional(string, "bx2")
family = optional(string, "balanced")
zone = optional(string, "us-south-1")
dedicated_host = list(object({
name = string
profile = optional(string, "bx2-host-152x608")
access_tags = optional(list(string), [])
}))
}))
n/a yes

Outputs

Name Description
dedicated_host_group_ids List the Dedicated Host Group ID's
dedicated_host_ids List the Dedicated Host ID's

Contributing

You can report issues and request features for this module in GitHub issues in the module repo. See Report an issue or request a feature.

To set up your local development environment, see Local development setup in the project documentation.