<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Can not set Service Principal User role to a service principal in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/can-not-set-service-principal-user-role-to-a-service-principal/m-p/98681#M39799</link>
    <description>&lt;P&gt;Hi!&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;I'm trying to assign `Service Principal Users` role to a newly create Service Principal using terraform.&lt;/P&gt;&lt;P&gt;For that I use following block of code:&lt;/P&gt;&lt;P&gt;```&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;resource&lt;/SPAN&gt; &lt;SPAN&gt;"databricks_service_principal_role"&lt;/SPAN&gt; &lt;SPAN&gt;"sp_job_runner_user_role"&lt;/SPAN&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; service_principal_id&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;databricks_service_principal&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;sp_job_runner&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;id&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; role&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;"roles/servicePrincipal.user"&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;}&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;```&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Terraform complains with following error when I execute `terraform apply`:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;```&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Error: cannot create service principal role: invalidValue Invalid role value roles/servicePrincipal.user&lt;BR /&gt;```&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;What's the valid role name I should use?&lt;/P&gt;&lt;P&gt;I would like to do the same thing as on the below image:&lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2024-11-13 at 15.30.56.png" style="width: 400px;"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/12870i3461E009A4681280/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Screenshot 2024-11-13 at 15.30.56.png" alt="Screenshot 2024-11-13 at 15.30.56.png" /&gt;&lt;/span&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;I need that SP to run a databricks jobs, but without that role I'm unable to assign this SP in the `run_as` field because of this error:&lt;/DIV&gt;&lt;DIV&gt;```&lt;/DIV&gt;&lt;DIV&gt;Error: cannot update job: Cannot bind the service principal provided in 'run_as' field (.....) to the job. The user creating or updating the job must have 'servicePrincipal.user' role on the service principal.&lt;/DIV&gt;&lt;DIV&gt;```&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Wed, 13 Nov 2024 14:39:51 GMT</pubDate>
    <dc:creator>jgrycz</dc:creator>
    <dc:date>2024-11-13T14:39:51Z</dc:date>
    <item>
      <title>Can not set Service Principal User role to a service principal</title>
      <link>https://community.databricks.com/t5/data-engineering/can-not-set-service-principal-user-role-to-a-service-principal/m-p/98681#M39799</link>
      <description>&lt;P&gt;Hi!&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;I'm trying to assign `Service Principal Users` role to a newly create Service Principal using terraform.&lt;/P&gt;&lt;P&gt;For that I use following block of code:&lt;/P&gt;&lt;P&gt;```&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;resource&lt;/SPAN&gt; &lt;SPAN&gt;"databricks_service_principal_role"&lt;/SPAN&gt; &lt;SPAN&gt;"sp_job_runner_user_role"&lt;/SPAN&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; service_principal_id&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;databricks_service_principal&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;sp_job_runner&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;id&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; role&lt;/SPAN&gt; &lt;SPAN&gt;=&lt;/SPAN&gt; &lt;SPAN&gt;"roles/servicePrincipal.user"&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;}&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;```&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Terraform complains with following error when I execute `terraform apply`:&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;```&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Error: cannot create service principal role: invalidValue Invalid role value roles/servicePrincipal.user&lt;BR /&gt;```&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;P&gt;What's the valid role name I should use?&lt;/P&gt;&lt;P&gt;I would like to do the same thing as on the below image:&lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2024-11-13 at 15.30.56.png" style="width: 400px;"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/12870i3461E009A4681280/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Screenshot 2024-11-13 at 15.30.56.png" alt="Screenshot 2024-11-13 at 15.30.56.png" /&gt;&lt;/span&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;I need that SP to run a databricks jobs, but without that role I'm unable to assign this SP in the `run_as` field because of this error:&lt;/DIV&gt;&lt;DIV&gt;```&lt;/DIV&gt;&lt;DIV&gt;Error: cannot update job: Cannot bind the service principal provided in 'run_as' field (.....) to the job. The user creating or updating the job must have 'servicePrincipal.user' role on the service principal.&lt;/DIV&gt;&lt;DIV&gt;```&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 13 Nov 2024 14:39:51 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/can-not-set-service-principal-user-role-to-a-service-principal/m-p/98681#M39799</guid>
      <dc:creator>jgrycz</dc:creator>
      <dc:date>2024-11-13T14:39:51Z</dc:date>
    </item>
    <item>
      <title>Re: Can not set Service Principal User role to a service principal</title>
      <link>https://community.databricks.com/t5/data-engineering/can-not-set-service-principal-user-role-to-a-service-principal/m-p/98686#M39802</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/85819"&gt;@jgrycz&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;Can you follow this block of code mentioned here:&amp;nbsp;&lt;A href="https://registry.terraform.io/providers/databricks/databricks/latest/docs/resources/access_control_rule_set" target="_blank"&gt;https://registry.terraform.io/providers/databricks/databricks/latest/docs/resources/access_control_rule_set&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Please note:&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Currently, we only support managing access rules on service principal, group and account resources through&amp;nbsp;&lt;/SPAN&gt;&lt;CODE&gt;databricks_access_control_rule_set&lt;/CODE&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 13 Nov 2024 15:23:06 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/can-not-set-service-principal-user-role-to-a-service-principal/m-p/98686#M39802</guid>
      <dc:creator>Alberto_Umana</dc:creator>
      <dc:date>2024-11-13T15:23:06Z</dc:date>
    </item>
    <item>
      <title>Re: Can not set Service Principal User role to a service principal</title>
      <link>https://community.databricks.com/t5/data-engineering/can-not-set-service-principal-user-role-to-a-service-principal/m-p/98745#M39830</link>
      <description>&lt;P&gt;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/106294"&gt;@Alberto_Umana&lt;/a&gt;&amp;nbsp;thanks for help!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 14 Nov 2024 07:21:56 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/can-not-set-service-principal-user-role-to-a-service-principal/m-p/98745#M39830</guid>
      <dc:creator>jgrycz</dc:creator>
      <dc:date>2024-11-14T07:21:56Z</dc:date>
    </item>
  </channel>
</rss>

