pbi-tools icon indicating copy to clipboard operation
pbi-tools copied to clipboard

AD Group deleted when deploying dataset to workspace

Open ingthu opened this issue 3 years ago • 7 comments

Hi!

When deploying the dataset then the AD group (for Row-Level Security) that exists in workspace is deleted. It would be good if the AD group can be kept even if you deploy.

I am using the 1.0.0-rc.2+preview.4 Hotfix Release

ingthu avatar Aug 16 '22 07:08 ingthu

That's a known limitation in the latest preview - all role members are currently reset when deploying. This will be fixed in the next release, expected before the end of August. An immediate workaround would be to declare the groups and users for each role in the TMSL sources.

mthierba avatar Aug 16 '22 08:08 mthierba

Thanks for your response!

ingthu avatar Aug 16 '22 08:08 ingthu

Is there an update on this? TMDL doesn't currently serialise role members so would like to be able to deploy without over writing role membership. Do you know if serialisation of role membership is on the road map for TMDL? Many thanks Ben

bcdobbs avatar Apr 13 '23 14:04 bcdobbs

Support for role members is coming in preview 2 or 3 of TMDL.

mthierba avatar Apr 15 '23 20:04 mthierba

Since it isn't fixed yet, here is more detail about the workaround:

  • If starting from pbix/pbit, generate TMSL instead of TMDL, for example using pbi-tools extract -modelSerialization Legacy
  • Following https://learn.microsoft.com/en-us/analysis-services/tmsl/roles-object-tmsl define for example an AD user role member by editing the Model/database.json file to get:
    "roles": [
      {
        "name": "Internet Sales Global",
        "description": "All users can query model data",
        "modelPermission": "read",
        "members": [
          {
            "memberName": "[email protected]",
            "identityProvider": "AzureAD"
          },
          {
            "memberName": "obj:group-id@tenant-id",
            "identityProvider": "AzureAD"
          }
        ],
        "tablePermissions": [
          // ...
        ]
      }
    ],

PHPirates avatar Sep 12 '23 12:09 PHPirates