terraform-provider-ibm icon indicating copy to clipboard operation
terraform-provider-ibm copied to clipboard

ibm_code_engine_binding resource is not 1:1 with code engine CLI implementation

Open akocbek opened this issue 11 months ago • 0 comments

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

Affected Resource(s)

  • ibm_code_engine_binding

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_code_engine_binding" "ce_binding" {
  project_id  = var.project_id
  prefix      = var.prefix
  secret_name = var.secret_name

  dynamic "component" {
    for_each = var.components != null ? var.components : []
    content {
      name          = component.value["name"]
      resource_type = component.value["resource_type"]
    }
  }
}

Debug Output

Panic Output

Expected Behavior

CLI/API service binding implementation is different from terraform implementation.

  1. IBM provider requires prefix attribute, but if I create service binding through UI prefix is optional attribute

terraform resource image

UI image

  1. If I create service binding through UI, then service credentials and secret access can be generated automatically. Using terraform resource I need to pass secret name, which must be created by me in front.

Actual Behavior

  1. prefix is optional attribute
  2. terraform resource would create service credentials and secrets automatically for me, the same as it is created using the UI

Steps to Reproduce

  1. terraform apply

Important Factoids

References

  • #0000

akocbek avatar Mar 22 '24 10:03 akocbek