I am trying to install ActivePerl in a Windows docker image based on mcr.microsoft.com/dotnet/framework/sdk:4.8-windowsservercore-ltsc2019
and it fails like this:
PS C:\TEMP> powershell -Command "& $([scriptblock]::Create((New-Object Net.WebClient).DownloadString('https://platform.activestate.com/dl/cli/install.ps1'))) -activate-default ActiveState/Perl-5.32"
At line:1 char:1
+ & # Copyright 2019 ActiveState Software Inc. All rights reserved.
+ ~
Missing expression after '&' in pipeline element.
At line:1 char:66
+ & # Copyright 2019 ActiveState Software Inc. All rights reserved.
+ ~
Unexpected token '
' in expression or statement.
At line:12 char:56
+ [Parameter(Mandatory=$False)][string]$b = 'release'
+ ~
Missing closing ')' in expression.
At line:24 char:55
+ ,[Parameter(Mandatory=$False)][string]$activate = "
+ ~
The string is missing the terminator: ".
At line:20 char:6
+ ,[Parameter(Mandatory=$False)]
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Unexpected attribute 'Parameter'.
At line:21 char:9
+ [ValidateScript({[IO.Path]::GetExtension($_) -eq '.exe'})]
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Unexpected attribute 'ValidateScript'.
+ CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordException
+ FullyQualifiedErrorId : MissingExpression
Is there anything I can do to fix the issue?