Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add 'multitenant' mode for elasticsearch and postgresql db resources #200

Merged
merged 4 commits into from
Sep 30, 2024

Conversation

luisarojas
Copy link
Collaborator

@luisarojas luisarojas commented Sep 28, 2024

Add support for multitenant flag to be used as host_flavor.id property in the ibm_database resource.

For example:

resource "ibm_database" "elasticsearch_enterprise_multitenant_flavor_auto_cpu_scale" {
  name     = "elasticsearch-enterprise-multitenant-flavor-auto-cpu-scale"
  service  = "databases-for-elasticsearch"
  plan     = "enterprise"
  location = "us-south"
  group {
    group_id = "member"
    host_flavor {
      id = "multitenant"
    }
    disk { # >= 5120 and <= 4194304 in increments of 1024
      allocation_mb = 5120
    }
    memory { # >= 4096 and <= 114688 in increments of 128
      allocation_mb = 4096
    }
    cpu {                  # >= 0 and <= 28 in increments of 1
      allocation_count = 0 # Automatically allocate based on a 1:8 ration with RAM
    }
  }
}

Would have a cost breakdown:

 ibm_database.elasticsearch_enterprise_multitenant_flavor_auto_cpu_scale                                    
 ├─ RAM (3 members)                                                                12  GB           $194.05 
 ├─ Disk (3 members)                                                               15  GB             $9.42 
 └─ Virtual Processor Cores (3 members)                                           1.5  CPU           $48.51 
Expected cost, provided by user (IBM DA team)

@luisarojas luisarojas self-assigned this Sep 28, 2024
@luisarojas luisarojas added enhancement New feature or request bugfix labels Sep 28, 2024
@luisarojas luisarojas requested a review from hiltol September 28, 2024 00:45
@luisarojas luisarojas requested a review from hiltol September 30, 2024 16:33
@hiltol hiltol merged commit a0c65bd into master Sep 30, 2024
6 of 7 checks passed
@hiltol hiltol deleted the fix/elasticsearch-postgresql-multitenant branch September 30, 2024 17:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants