Closed Ben8t closed 8 months ago
Closing this one. Like in any service, there is the need for the creation of first user/tenant The path is more something like: you obtain a license key, launch kestra UI/server for the first time and then you go check if your configuration was valid, check multitenancy, configure your first user and your first tenant and THEN you can manage your tenant with terraform
Related to https://github.com/kestra-io/kestra-ee/issues/601
Expected Behavior
During the initial provisioning of Kestra, users aren't automatically created. Although Terraform resources like kestra_user and kestra_user_password appear suitable for user creation during instance provisioning, they become unusable due to the requirement of a JWT token post-provisioning. This leads to the inability to automatically create users, hindering the login process to Kestra from a freshly provisioned instance.
Issue Details
Problem: Terraform resources (
kestra_user
,kestra_user_password
) can't be utilized post-provisioning due to the necessity of a JWT token for API access. Impact: Unable to log into Kestra from a newly provisioned instance without manually creating a user viaauths users create
command. Workaround: Manually SSH into the running Kestra instance on Kubernetes and create a user usingauths users create
command. Then, access the UI as the created user to obtain a JWT token. Update the Terraform provider's jwt field with this token for subsequent Terraform resource calls. Challenges: Inconvenience: Manual user creation and token update process are cumbersome and error-prone. Provisioning Limitation: Unable to fully automate provisioning using Terraform due to the manual intervention required for user creation and token updates. Token Expiry: Tokens expire, necessitating continual manual updates in the Terraform provider, leading to disruption in resource provisioning. Desired Outcome: Find a solution or alternative approach to enable automatic user creation during initial provisioning using Terraform without the dependency on JWT tokens post-provisioning. This would ensure a seamless and fully automated provisioning process for Kestra instances.Actual Behaviour
No response
Steps To Reproduce
No response
Environment Information
Example flow
No response