Skip to content

Conversation

@SteveL-MSFT
Copy link
Member

PR Summary

Windows Client machines have restricted execution policy by default, so that doesn't allow scripts (signed or not) to run which cases the PowerShell adapter to fail unless the user explicitly changes their execution policy. Instead, since DSC already sets the working directory to the location of the resource manifest, we can be assured that the intended adapter script gets run. Fix is to explicitly set execution policy to bypass, which won't override Group Policy.

PR Context

Fix #714

@SteveL-MSFT SteveL-MSFT added this pull request to the merge queue Apr 4, 2025
Merged via the queue into PowerShell:main with commit 82295d4 Apr 4, 2025
4 checks passed
@SteveL-MSFT SteveL-MSFT deleted the executionpolicy branch April 4, 2025 22:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

dsc resource list with --adapter flag returns with Exit code 1

2 participants