PowerShell

PowerShell is a cross-platform task automation framework and scripting language developed by Microsoft. Designed for system administrators and power users, it facilitates the automation of administrative tasks through a command-line shell and a scripting language, enabling efficient management of Windows and other operating systems.

Installation

Install powershellAUR or powershell-binAUR.

PowerShell Core can also be installed via the .NET SDK if this is already configured.

PowerShell remoting over SSH

PowerShell has a built-in remote management system via the PSSession cmdlets. This system can run over SSH. In order to configure a Linux SSH host for this, the sshd_config file needs the following line added:

/etc/ssh/sshd_config
Subsystem powershell /usr/bin/pwsh -sshs

It is then possible to use the New-PSSession, Enter-PSSession and Invoke-Command cmdlets to control the host. This can also be done from Linux to Windows or vice versa. For an usage example, see the Microsoft documentation.

See also

This article is issued from Archlinux. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.