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

Not able to create M0 clusters #64

Closed
jackivanov opened this issue Nov 8, 2019 · 3 comments
Closed

Not able to create M0 clusters #64

jackivanov opened this issue Nov 8, 2019 · 3 comments

Comments

@jackivanov
Copy link

jackivanov commented Nov 8, 2019

Hello,

For some reason I can't create M0 clusters via terraform. Meanwhile I can do it in the UI.

resource "mongodbatlas_cluster" "default" {
  name                        = "M0"
  project_id                  = mongodbatlas_project.backend.id
  provider_name               = "GCP"
  provider_region_name        = "WESTERN_EUROPE"
  provider_instance_size_name = "M0"
}

Error: error creating MongoDB Cluster: POST https://cloud.mongodb.com/api/atlas/v1.0/groups/XXX/clusters: 400 (request "Bad Request") An invalid enumeration value M0 was specified.

resource "mongodbatlas_cluster" "default" {
  name                        = "M0"
  project_id                  = mongodbatlas_project.backend.id
  provider_name               = "TENANT"
  provider_region_name        = "WESTERN_EUROPE"
  provider_instance_size_name = "M0"
}

Error: error creating MongoDB Cluster: POST https://cloud.mongodb.com/api/atlas/v1.0/groups/XXX/clusters: 400 (request "Bad Request") Invalid attribute instanceSizeName specified.

@jackivanov
Copy link
Author

API Access | You cannot modify or configure an M0 Free Tier cluster using the Clusters API endpoint. A subset of API endpoints support M2 and M5 shared clusters.

@ahanoff
Copy link

ahanoff commented Nov 22, 2019

@jackivanov I'm getting same error for M2/M5 clusters with AWS. Based on docs it should be available https://docs.atlas.mongodb.com/reference/api/clusters-create-one/ 🤔 ?

@ahanoff
Copy link

ahanoff commented Nov 22, 2019

All right, figure it out using correct provider_name and backing_provider_name for M2/M5:

auto_scaling_disk_gb_enabled = false

//Provider Settings "block"
provider_name = "TENANT"
backing_provider_name = "AWS"
disk_size_gb = 2
provider_instance_size_name = "M2"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants