Databricks.API.PowerShell icon indicating copy to clipboard operation
Databricks.API.PowerShell copied to clipboard

Piping not working with Set-DatabricksPermissions

Open saldroubi opened this issue 3 years ago • 1 comments

The command below is not working for setting the permissions on the cluster using piping.

$configObj | Add-DatabricksCluster | Pin-DatabricksCluster | Set-DatabricksPermissions -AccessControlList $acl

I had to do the following to make it work:

$clusterID = Add-DatabricksCluster -ClusterObject $configObj Pin-DatabricksCluster -ClusterID $clusterID.cluster_id Set-DatabricksPermissions -ClusterID $clusterID.cluster_id -AccessControlList $acl

saldroubi avatar Apr 25 '22 18:04 saldroubi

The problem is that Pin-DatabricksCluster does not return any value(s) to the pipe so Set-DatabricksPermissions cannot work properly

I added this with 1.9.9.9 so it should work now

gbrueckl avatar Apr 25 '22 19:04 gbrueckl

does this work now? can we close this issue?

gbrueckl avatar Oct 21 '22 12:10 gbrueckl

My apologies for the delay in testing this.
Yes, I just tested by changing my code to use piping and it is definitely working.

saldroubi avatar Oct 21 '22 15:10 saldroubi