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

terraform plan shows changes to read only attribute on stackit_ske_cluster #99

Open
lupa95 opened this issue Oct 24, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@lupa95
Copy link

lupa95 commented Oct 24, 2023

Expected Behavior

Terraform will not show changes to read only attributes on stackit_ske_cluster resource.

Current Behavior

Terraform shows planned changes to the read only attribute kubernetes_version_used.

# stackit_ske_cluster.example will be updated in-place
~ resource "stackit_ske_cluster" "example " {
      id                      = "1a143c23-8b0b-4dd8-8dd8-a5794773cde5,example-cluster"
    ~ kubernetes_version_used = "1.25.15" -> (known after apply)
      name                    = "wzk-cluster"
      # (5 unchanged attributes hidden)
  }

You can add this attribute to ignore_changes, but this is only a band-aid fix and terraform will (rightfully) display a warning about this:

│ Warning: Redundant ignore_changes element
│ 
│   on kubernetes.tf line 1, in resource "stackit_ske_cluster" "example ":
│    1: resource "stackit_ske_cluster" "example " {
│ 
│ Adding an attribute name to ignore_changes tells Terraform to ignore future changes to the argument in configuration after the object has been created, retaining the value originally
│ configured.
│ 
│ The attribute kubernetes_version_used is decided by the provider alone and therefore there can be no configured value to compare with. Including this attribute in ignore_changes has
│ no effect. Remove the attribute from ignore_changes to quiet this warning.

Steps to Reproduce

  1. Deploy stackit_ske_cluster resource via terraform
  2. Run terraform plan again.

Terraform version used: 1.5.7
Stackit provider version used: 0.6.0 (issue was already present on 0.3.0)

@joaopalet
Copy link
Contributor

Hello, thanks for your feedback!

This is a known issue that we already have planned to address. In the meantime, we have noticed that when adding a maintenance block to the configuration the issue does not seem to occur.

@joaopalet joaopalet added the bug Something isn't working label Oct 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants