airbytehq / airbytehq/terraform-provider-airbyte

Actual organization_id not imported into tfstate when importing airbyte_workspace resource

Abierto
#165 2 comentarios 0 reacciones 1 asignado Reclamado por @bgroff Ver en GitHub
Lenguaje dominante
Go
Estrellas
67
Forks
33
Merge medio
2 min
PR fusionados (30 d)
1

Descripción

I already have an existing Airbyte deployment (open source, version 1.4).
Now I want to import it into Terraform state.

What I did was that I prepared the code

```
resource "airbyte_workspace" "default_workspace" {
name = "Default Workspace"
organization_id = "00000000-0000-0000-0000-000000000000"
}
```

and run `terraform import airbyte_workspace.default_workspace "$my_workspace_id"`

however, the org ID was not imported into Terraform state
```
{
"mode": "managed",
"type": "airbyte_workspace",
"name": "default_workspace",
"provider": "provider[\"registry.terraform.io/airbytehq/airbyte\"]",
"instances": [
{
"schema_version": 0,
"attributes": {
"data_residency": "auto",
"name": "Default Workspace",
"organization_id": null, <---- there should be a "00000000-0000-0000-0000-000000000000"
"workspace_id": "$my_workspace_id"
},
"sensitive_attributes": []
}
]
},
```

As a result, the next runs of `terarform plan` result in Terraform wanting to replace the workspace.
I fixed the issue by manually editing the state and adding the proper org ID, however this shouldn't require a manual intervention.

My Terraform version:
```
Terraform v1.9.1
on darwin_arm64
+ provider registry.terraform.io/airbytehq/airbyte v0.6.5
```

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.