Skip to content

[terraform] - "provider["registry.terraform.io/infisical/infisical"]" produced an unexpected new value #231

@acaciochinato

Description

@acaciochinato

Describe the bug

Unable to use Terraform resource infisical_identity_kubernetes_auth.

When trying to apply the following code, terraform outputs: Provider produced inconsistent result after apply

# Using normal API as token reviewer mode
resource "infisical_identity" "kubernetes-infisical-token-reviewer" {
  name   = "kubernetes-infisical-token-reviewer"
  role      = "member"
  org_id  = var.infisical_organization_id
}

resource "infisical_identity_kubernetes_auth" "kubernetes-infisical-token-reviewer" {
  identity_id                  = infisical_identity.kubernetes-infisical-token-reviewer.id
  kubernetes_host       = var.cluster_host
  token_reviewer_jwt   = kubernetes_secret.infisical-auth-token.metadata[0].name
  kubernetes_ca_certificate = var.kubernetes_ca_certificate
  allowed_audience          = "infisical"
  access_token_ttl          = 2592000
  access_token_max_ttl      = 2592000
  token_reviewer_mode       = api
}
╷
│ Error: Provider produced inconsistent result after apply
│ 
│ When applying changes to module.k8s-core.infisical_identity_kubernetes_auth.kubernetes-infisical-token-reviewer, provider "provider[\"registry.terraform.io/infisical/infisical\"]" produced an unexpected new value:
│ .token_reviewer_mode: was cty.StringVal("api"), but now cty.StringVal("").
│ 
│ This is a bug in the provider, which should be reported in the provider's own issue tracker.
╵
failed to wait for command termination: exit status 1

Expected behavior

After issuing terraform apply the resource should be created

Platform you are having the issue on:

Self-hosted Infisical Version: v0.113.0-postgres running on container

Additional context

Add any other context about the problem here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions