I'm calling a workflow from rest. (From VMware VCO) When I call the workflow from the WFA portal, the powershell is executed as the user who is running the service. When I run the workflow via a REST call, I get errors.
re Permissions - BASE] ### Command 'Grant Share Permissions - BASE' ###
13:58:32.148 ERROR [Grant Share Permissions - BASE] Command failed for Workflow 'Create a Clustered Data ONTAP Qtree CIFS Share - mszafran' with error : \\SVM_MSZAFRAN\qtreevco2: Access is denied.
13:58:32.152 INFO [Grant Share Permissions - BASE] ***** Workflow Execution Failed *****
Here are the offending commands:
icacls \\$NetbiosServer\$ShareName /grant $DomainName\"$RWGroupName":"(OI)(CI)M"
icacls \\$NetbiosServer\$ShareName /grant $DomainName\"$ROGroupName":"(OI)(CI)RX"
icacls \\$NetbiosServer\$ShareName /remove "Everyone"
What is best to do here? Is there a powershell equivalent of sudo or something that is spiffy for this?