Install PowerShell on Ubuntu 18.04

Recently i had to install Powershell on my Ubuntu servers in order to run some ansible playbook on vCenter.
I am using on Ubuntu 18.04, which by default Powershell modules not part of server and we have to use the following command in order to be able use powershell commands:

sudo update update && sudo apt -y install wget
wget -q https://packages.microsoft.com/config/ubuntu/18.04/packages-microsoft-prod.deb
sudo dpkg -i packages-microsoft-prod.deb
sudo apt update
sudo apt -y install powershell

Then run:

pwsh

And you can see that Powershell is installed:

Leave a Comment

Your email address will not be published.

Comment moderation is enabled. Your comment may take some time to appear.

In the news
Load More