Powershell JEA not working

Ádám Tóth 116 Reputation points
2021-10-22T12:28:41.533+00:00

Hi,

I created a JEA config for a server in PowerShell, but one command not working in the user's JEA session.

I put two commands to my Role Configuration file:

VisibleCmdlets =

@{ 'Get-ScheduledTask' ; Parameters = @{Name = 'TaskName' ; ValidateSet = 'TestTask'}},

@{ 'Get-Service' ; Parameters = @{Name = 'Name' ; ValidateSet = 'spooler'}}

He is able to run the "Get-Service spooler" command in his JEA session, but when he try to run the "Get- ScheduledTask -Taskname TestTask" command, he is getting this error:

the term ' Get-ScheduledTask ' is not recognized as the name of a cmdlet

Why JEA can't recognize the Get- ScheduledTask command?

Windows for business | Windows Server | User experience | PowerShell
{count} votes

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.