Closed pva2007 closed 2 days ago
The problem here as a datasource is that the client_secret is only provided at creation or if the secret is newly generated, do we maybe have to change this logic? @hifabienne
The problem here as a datasource is that the client_secret is only provided at creation or if the secret is newly generated, do we maybe have to change this logic? @hifabienne
In my opinion from an api perspective in ZITADEL this makes sense as it is. But not sure how it should be in the terraform provider. I also don't really get why this is the problem. In the issue description it talks about creating a client, why does it not get the secret in that case?
@pva2007 The ZITADEL API only returns the client secret when it is created. After that, there is no way to read the secret from the ZITADEL API anymore.
If you want to have the client secret in your Terraform state so you can reference it, either create a new app using Terraform or import the resource by providing the secret.
Please create an issue related to the regeneration of the secret if necessary, but for the datasource I still see no way besides the import.
Preflight Checklist
Version
1.7.0
ZITADEL Version
v2.43.3
Describe the problem caused by this bug
I'm creating an application in a project which work as expected with OIDC_GRANT_TYPE_AUTHORIZATION_CODE, but I'm unable to obtain the client_id/ client_secret from the created application for further usage. Neither data sources zitadel_org_oidc_idp nor zitadel_application_oidc.
Documentatio satte these are available read_only: https://registry.terraform.io/providers/zitadel/zitadel/latest/docs/data-sources/org_oidc_idp#client_id
To reproduce
Creation of a zitadel_application_oidc ressource:
creating data resources:
All below options don't provide values and throw errors:
Screenshots
No response
Expected behavior
Either data ressource zitadel_org_oidc_idp or zitadel_application_oidc abel to provide the sensitive values.
Relevant Configuration
No response
Additional Context
No response