Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add note on Powershell execution policies to docs.zowe.org/stable/troubleshoot/cli/troubleshoot-cli #3934

Open
adam-wolfe opened this issue Oct 8, 2024 · 1 comment · May be fixed by #3999
Assignees
Labels
area: cli This issue is related to Zowe Command Line Interface (CLI)

Comments

@adam-wolfe
Copy link
Collaborator

adam-wolfe commented Oct 8, 2024

Description

Powershell users on Windows can encounter an error when they try to run Zowe CLI with certain execution policies in place.

An example of the error message:

PS C:\> zowe
zowe : File C:\Users\user\AppData\Roaming\npm\zowe.ps1 cannot be loaded because running scripts is disabled on this
system. For more information, see about_Execution_Policies at https:/go.microsoft.com/fwlink/?LinkID=135170.
At line:1 char:1
+ zowe
+ ~~~~
    + CategoryInfo          : SecurityError: (:) [], PSSecurityException
    + FullyQualifiedErrorId : UnauthorizedAccess

To resolve this issue, users will need to either:

  1. Change a setting in "Developer Settings" in Windows 10 settings (I am not sure where they can find this setting in other versions of Windows) to enable running local scripts without signing:
    image

  2. Or, they can run Powershell as an administrator and use the Set-ExecutionPolicy command to change the execution policy to a less-restrictive setting, for example: Set-ExecutionPolicy RemoteSigned -scope CurrentUser.

Pages to Update

https://docs.zowe.org/stable/troubleshoot/cli/troubleshoot-cli

Screenshots

Expected behavior

Additional context

@1000TurquoisePogs
Copy link
Member

I believe this is what it looks like for windows 11
image

@t1m0thyj t1m0thyj added the area: cli This issue is related to Zowe Command Line Interface (CLI) label Oct 10, 2024
@github-project-automation github-project-automation bot moved this to New Issues in Zowe CLI Squad Oct 10, 2024
@anaxceron anaxceron self-assigned this Oct 30, 2024
@anaxceron anaxceron linked a pull request Nov 13, 2024 that will close this issue
@anaxceron anaxceron linked a pull request Nov 13, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: cli This issue is related to Zowe Command Line Interface (CLI)
Projects
Status: New Issues
Development

Successfully merging a pull request may close this issue.

4 participants