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

IBM Cloud Terraform provider 1.72.0 version seems to have broken ibm_is_volume resource #5864

Open
ileneruth opened this issue Dec 10, 2024 · 2 comments
Labels
service/VPC Infrastructure Issues related to the VPC Infrastructure

Comments

@ileneruth
Copy link

The ibm_is_volume resource cannot successfully create volumes after the following commit

caa07a4

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Terraform CLI and Terraform IBM Provider Version

It fails with 1.72.0 and 1.72.1

It works with 1.71.3

Affected Resource(s)

  • ibm_is_volume

Terraform Configuration Files

Please include all Terraform configurations required to reproduce the bug. Bug reports without a functional reproduction may be closed without investigation.

resource "ibm_is_volume" "logDisk1" {
  // Name must be lower case
  name           = "${var.CLUSTER_NAME}-logdisk1-${random_string.random_suffix.result}"
  profile        = "10iops-tier"
  zone           = var.ZONE
  resource_group = var.RESOURCE_GROUP
  encryption_key = var.LOGDISK_ENCRYPTION_KEY
}

Debug Output

Panic Output

Expected Behavior

Resource should be created.

Actual Behavior

This error

2024/12/09 18:57:04 Terraform apply | Error: [DEBUG] Create volume err Expected at least one anyOf fields to be set
2024/12/09 18:57:04 Terraform apply | {
2024/12/09 18:57:04 Terraform apply | "StatusCode": 400,
2024/12/09 18:57:04 Terraform apply | "Headers": {
2024/12/09 18:57:04 Terraform apply | "Allow-Snippet-Annotations": [
2024/12/09 18:57:04 Terraform apply | "true"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "Cache-Control": [
2024/12/09 18:57:04 Terraform apply | "max-age=0, no-cache, no-store, must-revalidate"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "Cf-Cache-Status": [
2024/12/09 18:57:04 Terraform apply | "DYNAMIC"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "Cf-Ray": [
2024/12/09 18:57:04 Terraform apply | "8ef732fb3c16abfa-YYZ"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "Content-Length": [
2024/12/09 18:57:04 Terraform apply | "586"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "Content-Type": [
2024/12/09 18:57:04 Terraform apply | "application/json; charset=utf-8"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "Date": [
2024/12/09 18:57:04 Terraform apply | "Mon, 09 Dec 2024 18:53:38 GMT"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "Expires": [
2024/12/09 18:57:04 Terraform apply | "-1"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "Pragma": [
2024/12/09 18:57:04 Terraform apply | "no-cache"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "Server": [
2024/12/09 18:57:04 Terraform apply | "cloudflare"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "Strict-Transport-Security": [
2024/12/09 18:57:04 Terraform apply | "max-age=31536000; includeSubDomains"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "X-Content-Type-Options": [
2024/12/09 18:57:04 Terraform apply | "nosniff"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "X-Correlation-Id": [
2024/12/09 18:57:04 Terraform apply | "0f36f146-7c8c-4a1f-ad2e-bbc4a01016fe"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "X-Request-Id": [
2024/12/09 18:57:04 Terraform apply | "e8bb8060-d200-4a6d-b607-15a46af381e7"
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "X-Xss-Protection": [
2024/12/09 18:57:04 Terraform apply | "1; mode=block"
2024/12/09 18:57:04 Terraform apply | ]
2024/12/09 18:57:04 Terraform apply | },
2024/12/09 18:57:04 Terraform apply | "Result": {
2024/12/09 18:57:04 Terraform apply | "errors": [
2024/12/09 18:57:04 Terraform apply | {
2024/12/09 18:57:04 Terraform apply | "code": "validation_failed_anyof",
2024/12/09 18:57:04 Terraform apply | "message": "Expected at least one anyOf fields to be set",
2024/12/09 18:57:04 Terraform apply | "target": {
2024/12/09 18:57:04 Terraform apply | "name": "VolumePrototype",
2024/12/09 18:57:04 Terraform apply | "type": "field"
2024/12/09 18:57:04 Terraform apply | }
2024/12/09 18:57:04 Terraform apply | },
2024/12/09 18:57:04 Terraform apply | {
2024/12/09 18:57:04 Terraform apply | "code": "validation_failed_required",
2024/12/09 18:57:04 Terraform apply | "message": "VolumeByCapacity is invalid: Validation Failure for field: capacity",
2024/12/09 18:57:04 Terraform apply | "target": {
2024/12/09 18:57:04 Terraform apply | "name": "VolumeByCapacity.capacity",
2024/12/09 18:57:04 Terraform apply | "type": "field"
2024/12/09 18:57:04 Terraform apply | }
2024/12/09 18:57:04 Terraform apply | },
2024/12/09 18:57:04 Terraform apply | {
2024/12/09 18:57:04 Terraform apply | "code": "validation_failed_required",
2024/12/09 18:57:04 Terraform apply | "message": "VolumeBySourceSnapshot is invalid: Validation Failure for field: source_snapshot",
2024/12/09 18:57:04 Terraform apply | "target": {
2024/12/09 18:57:04 Terraform apply | "name": "VolumeBySourceSnapshot.source_snapshot",
2024/12/09 18:57:04 Terraform apply | "type": "field"
2024/12/09 18:57:04 Terraform apply | }
2024/12/09 18:57:04 Terraform apply | }
2024/12/09 18:57:04 Terraform apply | ],
2024/12/09 18:57:04 Terraform apply | "trace": "e8bb8060-d200-4a6d-b607-15a46af381e7"
2024/12/09 18:57:04 Terraform apply | },
2024/12/09 18:57:04 Terraform apply | "RawResult": null
2024/12/09 18:57:04 Terraform apply | }
2024/12/09 18:57:04 Terraform apply |
2024/12/09 18:57:04 Terraform apply |
2024/12/09 18:57:04 Terraform apply | with module.fortigate-ha["1"].ibm_is_volume.logDisk1,
2024/12/09 18:57:04 Terraform apply | on modules/fortigate-ha/instance.tf line 5, in resource "ibm_is_volume" "logDisk1":
2024/12/09 18:57:04 Terraform apply | 5: resource "ibm_is_volume" "logDisk1" {

Steps to Reproduce

Try to create an ibm_is_volume resource based on sample usage documentation, such as

resource "ibm_is_volume" "example" {
name = "example-volume"
profile = "10iops-tier"
zone = "us-south-1"
}

  1. terraform apply

Important Factoids

Creating in ca-tor-1

This is what it thinks it's going to create during plan

  • resource "ibm_is_volume" "logDisk1" {
    + access_tags = (known after apply)
    + adjustable_capacity_states = (known after apply)
    + adjustable_iops_states = (known after apply)
    + bandwidth = (known after apply)
    + capacity = (known after apply)
    + catalog_offering = (known after apply)
    + crn = (known after apply)
    + encryption_key = (known after apply)
    + encryption_type = (known after apply)
    + health_reasons = (known after apply)
    + health_state = (known after apply)
    + id = (known after apply)
    + iops = (known after apply)
    + name = (known after apply)
    + operating_system = (known after apply)
    + profile = "10iops-tier"
    + resource_controller_url = (known after apply)
    + resource_crn = (known after apply)
    + resource_group = (known after apply)
    + resource_group_name = (known after apply)
    + resource_name = (known after apply)
    + resource_status = (known after apply)
    + source_snapshot = (known after apply)
    + source_snapshot_crn = (known after apply)
    + status = (known after apply)
    + status_reasons = (known after apply)
    + tags = (known after apply)
    + zone = "ca-tor-1"
    }

References

  • #0000
@github-actions github-actions bot added the service/VPC Infrastructure Issues related to the VPC Infrastructure label Dec 10, 2024
@ileneruth ileneruth changed the title Update seems to have broken ibm_is_volume resource IBM Cloud Terraform provider 1.72.0 version seems to have broken ibm_is_volume resource Dec 11, 2024
@ujjwal-ibm
Copy link
Collaborator

#5865

Created a fix for it. Alternatively if you provide capacity it should resolve the issue.

@ileneruth
Copy link
Author

Thank you for the workaround. For now, I will wait for the update instead of changing our automation scripts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
service/VPC Infrastructure Issues related to the VPC Infrastructure
Projects
None yet
Development

No branches or pull requests

2 participants