diff --git a/docker/release/nanoserver/Dockerfile b/docker/release/nanoserver/Dockerfile index 6e3d65fe03d..a712eab4e0d 100755 --- a/docker/release/nanoserver/Dockerfile +++ b/docker/release/nanoserver/Dockerfile @@ -17,7 +17,7 @@ ENV PS_DOWNLOAD_URL https://github.com/PowerShell/PowerShell/releases/download/v SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] RUN if (!($env:PS_VERSION -match '^\d+\.\d+\.\d+(-\w+(\.\d+)?)?$' )) {throw ('PS_Version ({0}) must match the regex "^\d+\.\d+\.\d+(-\w+(\.\d+)?)?$"' -f $env:PS_VERSION)} -RUN Invoke-WebRequest $Env:PS_DOWNLOAD_URL -OutFile powershell.zip +ADD $PS_DOWNLOAD_URL /powershell.zip RUN Expand-Archive powershell.zip -DestinationPath \PowerShell