| sidebar_position | 9 |
|---|
With PowerShell you can launch PowerShell consoles locally or connect to remote computers using PowerShell Remoting. You can also execute command-line applications such as wsl, k9s, or any other tools typically accessible from a PowerShell session. In addition, you can run PowerShell scripts directly within the console.
The integration of PuTTY with NETworkManger supports tabs and profiles for hosts (and tools). You can launch the console / establish a connection via a profile (double-click, Enter key or right-click Connect) or directly via the connection dialog.
:::info
PowerShell is a command-line shell and scripting language developed by Microsoft for automating administrative tasks and managing system configurations. It provides a robust set of built-in commands and access to .NET Framework objects, allowing for efficient system administration and automation. PowerShell uses a verb-noun syntax, allowing users to perform a wide range of operations by executing simple and powerful commands.
:::
:::note
Windows PowerShell and PowerShell are supported. Indructions for installing PowerShell Core can be found on the official website.
:::
:::tip
Launching a command-line application such as wsl or k9s can be done by passing the command to the PowerShell console.
# Connect to WSL
wsl -d <DISTRIBUTION>
# Connect to Kubernetes
k9s --readonlySee FAQ > PowerShell with command-line applications for more information.
:::
:::warning
If Windows Terminal is installed, change the Default terminal application in the settings of Windows Terminal to Windows Console Host instead of Windows Terminal to use PowerShell in NETworkManager.
:::
:::note
Right-click on the tab will open the context menu with the following options:
- Reconnect - Restart the PowerShell console (and reconnect to the remote computer).
- Resize - Resize the PowerShell console to the current view size (if connected).
:::
Connect to a remote computer via PowerShell Remoting.
Type: Boolean
Default: False
Host name or IP address of the remote computer.
Type: String
Default: Empty
Example:
server-01.borntoberoot.net10.0.0.10
:::note
Only available if Remote console is enabled.
:::
Command to execute when the PowerShell console is started locally.
Type: String
Default: Settings > Command
Example: Set-Location ~; Get-ChildItem
:::note
Only available if Remote console is disabled.
:::
:::tip
Use wsl -d <DISTRIBUTION> to connect to Windows Subsystem for Linux.
:::
Additional command line arguments to pass to the PowerShell console when it is started.
Type: String
Default: Settings > Additional command line
Execution policy of the PowerShell console when it is started.
Type: NETworkManager.Models.PowerShell.ExecutionPolicy
Default: Settings > Execution policy
Possible values:
RestrictedAllSignedRemoteSignedUnrestrictedBypass
Connect to a remote computer via PowerShell Remoting.
Type: Boolean
Default: Enabled
Inherit the host from the general settings.
Type: Boolean
Default: Enabled
:::note
If this option is enabled, the Host is overwritten by the host from the general settings and the Host is disabled.
:::
Host name or IP address of the remote computer.
Type: String
Example:
server-01.borntoberoot.net10.0.0.10
:::note
Only available if Remote console is enabled.
:::
Command to execute when the PowerShell console is started locally.
Type: String
Default: Empty
Example: Set-Location ~; Get-ChildItem
:::note
Only available if Remote console is disabled.
:::
:::tip
Use wsl -d <DISTRIBUTION> to connect to Windows Subsystem for Linux.
Use k9s or k9s --readonly to manage Kubernetes clusters.
:::
Additional command line arguments to pass to the PowerShell console when it is started.
Type: String
Default: Empty
Execution policy of the PowerShell console when it is started.
Type: NETworkManager.Models.PowerShell.ExecutionPolicy
Default: RemoteSigned
Possible values:
RestrictedAllSignedRemoteSignedUnrestrictedBypass
Command to execute when the PowerShell console is started locally.
Type: String
Default: Empty
Example: Set-Location ~; Get-ChildItem
:::tip
Use wsl -d <DISTRIBUTION> to connect to Windows Subsystem for Linux.
Use k9s or k9s --readonly to manage Kubernetes clusters.
:::
Additional command line arguments to pass to the PowerShell console when it is started.
Type: String
Default: Empty
Execution policy of the PowerShell console when it is started.
Type: NETworkManager.Models.PowerShell.ExecutionPolicy
Default: RemoteSigned
Possible values:
RestrictedAllSignedRemoteSignedUnrestrictedBypass
Path to the PowerShell console.
Type: String
Default: %ProgramFiles%\PowerShell\7\pwsh.exe, %ProgramFiles(x86)%\PowerShell\7\pwsh.exe or %windir%\System32\WindowsPowerShell\v1.0\powershell.exe
Example:
C:\Program Files\PowerShell\7\pwsh.exe
:::note
The Configure button opens the PowerShell console to configure it.
:::
Default command to execute when the PowerShell console is started locally.
Type: String
Default: Set-Location ~
Example: Set-Location ~; Get-ChildItem
:::tip
Use wsl -d <DISTRIBUTION> to connect to Windows Subsystem for Linux.
Use k9s or k9s --readonly to manage Kubernetes clusters.
:::
Default additional command line arguments to pass to the PowerShell console when it is started.
Type: String
Default: Empty
Default execution policy of the PowerShell console when it is started.
Type: NETworkManager.Models.PowerShell.ExecutionPolicy
Default: RemoteSigned
Possible values:
RestrictedAllSignedRemoteSignedUnrestrictedBypass
