- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-05-2022 01:35 PM
POWERSHELL ACTION IN FLOW DESIGNER EXECUTES AS SYSTEM USER BUT FAILES AS LOGGED-IN USER
I am trying to consume a powershell action in flow designer; the powershell is running on midserver as system user instead of user provided in connection details.
Snippet of result when I try to use command 'whoami'
This user is not having access to content which I am trying to read & edit - and the action fails with error as below:
and error code is having userid as passed in credential of this step.
Is there any way we can change the execution-user to be same as user passed in credentials instead of system account.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-02-2022 09:48 AM
It is resolved, the service account which was running midserver as service on OS was culprit. Once changed it from system to user-account; the system was no longer reproducible.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-07-2022 11:34 AM
Hi,
If this user is the same as the user who starts the flow, you can change the Flow properties:
Run As - 'User who initiates session'
Note: that affects the executions of other actions within the flow.
Best Regards,
Marcin
If my answer helped you in any way, please mark this answer as helpful and correct.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-02-2022 09:49 AM
The service account which was running midserver as service on OS was culprit. Once changed it from system to user-account; the system was no longer reproducible.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-07-2022 10:17 PM
Hi Yathrath,
I am having same requirement and I am new to powershell.
Could you please guide me on the steps how to call powershell action in Flow designer.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-02-2022 09:50 AM
You need to activate a plugin for enabling powershell action in flow designer and then consume the same.