Powershell: Please support Ubuntu 20.04

Created on 12 May 2020  路  29Comments  路  Source: PowerShell/PowerShell

Details of the Distribution

  • Name of the Distribution: Ubuntu
  • Version of the Distribution: 20.04
  • Processor Architecture (One per request):
  • [x] Required - An issues has been filed to create a Docker image in https://github.com/powershell/powershell-docker
  • The following is a requirement for supporting a distribution without exception.
  • The following are requirements for supporting a distribution.
    Please write a justification for any exception where these criteria are not met and
    the PowerShell comittee will review the request.

    • [x] The version of the Distribution is supported for at least one year.

    • [x] The version of the Distribution is not an interim release or equivalent.

Progress - For PowerShell Team ONLY

  • [x] Docker image created
  • [x] Docker image published
  • [x] Distribution tested
  • [ ] Update packages.microsoft.com deployment
  • [ ] Lifecycle updated
  • [ ] Documentation Updated

Further adding to this Ubuntu 20.04 is an LTS so releasing a supported version of this would be a good long term investment for the community

I would love to see a 7.0 release for it (LTS with another LTS) but expect a retro release would not be feasible so if this could fit in for a 7.1 release that would be great

BackPort-7.0.x-Approved Distribution-Request

Most helpful comment

I've just done dotnet tool install -g powershell on my 20.04 WSL and it has installed 7.0.1

Updated to add:

My dotnet --info gives:

.NET Core SDK (reflecting any global.json):
 Version:   3.1.202
 Commit:    6ea70c8dca

Runtime Environment:
 OS Name:     ubuntu
 OS Version:  20.04
 OS Platform: Linux
 RID:         linux-x64
 Base Path:   /usr/share/dotnet/sdk/3.1.202/

Host (useful for support):
  Version: 3.1.4
  Commit:  0090613580

.NET Core SDKs installed:
  3.1.202 [/usr/share/dotnet/sdk]

.NET Core runtimes installed:
  Microsoft.AspNetCore.App 3.1.4 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 3.1.4 [/usr/share/dotnet/shared/Microsoft.NETCore.App]

All 29 comments

The corresponding Docker request is https://github.com/PowerShell/PowerShell-Docker/issues/404 - thanks to @TravisEz13

& doing so would properly fix this issue - https://github.com/MicrosoftDocs/PowerShell-Docs/issues/5906

This one is pretty obvious. I won't send this to the committee. Let's consider this approved. We need a tar.gz based container to do the testing.

With the new .Net Core 3.1.4 (and 2.1.18) runtime release yesterday, .Net has added support for Ubuntu 20.04: https://github.com/dotnet/core/blob/master/release-notes/3.1/3.1.4/3.1.4.md#net-core-lifecycle-news

Up so @msftbot doesn't close it. sudo snap install powershell --classic still doesn't install required version on .net.

@superbonaci Please use https://github.com/powerShell/powershell-snap to discuss issues with the snap package. Specifically, https://github.com/PowerShell/PowerShell-Snap/issues/65

GitHub
Contribute to PowerShell/PowerShell-Snap development by creating an account on GitHub.

Interestingly, the 16.04 package for 7.0.1 successfully installs on 20.04

I've just done dotnet tool install -g powershell on my 20.04 WSL and it has installed 7.0.1

Updated to add:

My dotnet --info gives:

.NET Core SDK (reflecting any global.json):
 Version:   3.1.202
 Commit:    6ea70c8dca

Runtime Environment:
 OS Name:     ubuntu
 OS Version:  20.04
 OS Platform: Linux
 RID:         linux-x64
 Base Path:   /usr/share/dotnet/sdk/3.1.202/

Host (useful for support):
  Version: 3.1.4
  Commit:  0090613580

.NET Core SDKs installed:
  3.1.202 [/usr/share/dotnet/sdk]

.NET Core runtimes installed:
  Microsoft.AspNetCore.App 3.1.4 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 3.1.4 [/usr/share/dotnet/shared/Microsoft.NETCore.App]

I've just done dotnet tool install -g powershell on my 20.04 WSL and it has installed 7.0.1

But is that equivalent to sudo snap install powershell --classic or what is the difference?

@superbonaci

But is that equivalent to sudo snap install powershell --classic or what is the difference?

dotnet tool install uses the dotnet sdk install to get the dotnet native dependencies, meaning you are actually running on the host os binaries.

In snap, you are running in a containerized environment, the base layer is current 18.04, the PowerShell snap bring PowerShell and dotnet that work against the 18.04 layer, with access to your host OS.

@superbonaci Kind of in the sense that it gets the job done from a user's perspective.
Depending on the use case this might be just a workaround though because you need to think about updating that version in the future. The dotnet tool has an update command but not yet a command to update all installed tools. For a local dev environment, it's probably OK as a workaround but I wouldn't use this way for distributing it across machines due to the maintenance overhead. Ideally you only want to use 1-2 package managers and avoid using too many different package managers.

@superbonaci no we can't - until there is a binary that can be installed on 20.04

you can however go and update the docs page sayin that it can work via snap, though I can't get this working with Ubuntu 20.04 on WSL via Snap

Perhaps we should update the distribution request template to say that snap support is off topic and those issues should be discussed in the PowerShell/PowerShell-snap repo.

I made the change.
https://github.com/PowerShell/PowerShell/blob/master/.github/ISSUE_TEMPLATE/Distribution_Request.md

GitHub
PowerShell for every system! Contribute to PowerShell/PowerShell development by creating an account on GitHub.

I've just done dotnet tool install -g powershell on my 20.04 WSL and it has installed 7.0.1

That method wouldn't work for me but after installing dotnet-sdk-3.1 and dotnet-runtime-3.1 the following command allowed Powershell v7.0.1 to install without error on 20.04 -> sudo snap install powershell --classic

@mattduguid that also worked for me:
sudo snap install powershell --classic sudo snap install dotnet-sdk --classic

The instructions on the Docs actually works, but you need to type powershell instead of pwsh.

Stop marking comments as off-topic.

Stop marking comments as off-topic.

@superbonaci Please make comments about snap in the snap repo. This issue is not about the snap or dotnet tool which are distribution agnostic (in theory). The snap is a topic not even covered in this repo, definitely off topic.

Please support Us

If you can't use the snap package because of missing dependencies for PS remoting: The container image works just fine.

I have installed it with Dotnet dependency, but now I am having trouble logging in, I get an error of this client.Subscription cannot be found

dotnet tool install -g powershell

This also worked for me on WSL 2 Ubuntu 20.04, and while that's great, I'd rather have the OS wide install. Seems that, just getting the package dependencies sorted for 20.04 is all that is needed since the binary works fine.

Just upvoting this... can't believe that 20.04 has been out for two months and isn't supported still? This is the LTS build... this will become standard very soon for anyone installing Ubuntu. Please consider expediting!

Please support Ubuntu 20.04. Thanks.

bump

This is approved and in progress.
This is supported at this point.
Distribution and documentation are pending.
Locking conversation so we can focus on the work.

This is not fixed. @SteveL-MSFT Please make sure all the work is done before closing

Just in case, duplicating instructions link from the main page here:
Installation instructions for Ubuntu 20.04

Was this page helpful?
0 / 5 - 0 ratings