-
Notifications
You must be signed in to change notification settings - Fork 446
Fix reading of external_id
for databricks_service_principal
#4712
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
Conversation
During work on exporter I found that `external_id` wasn't filled for service principals and this lead to a problem with generation of correct code. The `databricks_user` had the correct code, so I unified the things
…vice principals We should generate `application_id` only for Azure-managed service principals, while Databricks-managed SPs should have only name. Should be merged after #4712
@@ -101,12 +109,8 @@ func ResourceUser() common.Resource { | |||
if err != nil { | |||
return err | |||
} | |||
setCommonUserFields(d, user, user.UserName) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can remove passing user.UserName since we are passing user so inside setCommonUserFields, we can use user.UserName directly.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's required because we need to pass different attributes (UserName for user and ApplicationId for service principal)
If integration tests don't run automatically, an authorized user can run them manually by following the instructions below: Trigger: Inputs:
Checks will be approved automatically on success. |
…vice principals (#4716) ## Changes <!-- Summary of your changes that are easy to understand --> We should generate `application_id` only for Azure-managed service principals, while Databricks-managed SPs should have only name. Should be merged after #4712 ## Tests <!-- How is this tested? Please see the checklist below and also describe any other relevant tests --> - [x] `make test` run locally - [ ] relevant change in `docs/` folder - [ ] covered with integration tests in `internal/acceptance` - [ ] using Go SDK - [ ] using TF Plugin Framework
## Release v1.80.0 ### New Features and Improvements * Add `resource_model_serving_provisioned_throughput` for creation of [model serving provisioned throughput](https://docs.databricks.com/aws/en/machine-learning/foundation-model-apis/deploy-prov-throughput-foundation-model-apis) endpoints [#4701](#4701) * Replace DBFS with Unity Catalog resources in [index page](https://registry.terraform.io/providers/databricks/databricks/latest/docs) storage section [#4718](#4718) ### Bug Fixes * Support updating all attributes for `databricks_model_serving` ([#4575](#4575)). * Fix reading of `external_id` for `databricks_service_principal` [#4712](#4712) ### Documentation * Added documentation for GITHUB OIDC authentication type [#4717] (#4717) ### Exporter * Generate correct code for Databricks and Azure-managed service principals [#4715](#4715)
Changes
During work on exporter I found that
external_id
wasn't filled for service principals and this lead to a problem with generation of correct code. Thedatabricks_user
had the correct code, so I unified the thingsTests
make test
run locallydocs/
folderinternal/acceptance