diff --git a/22/windows-2019/Dockerfile b/22/windows-2019/Dockerfile index c2ea797d6..2ca2a9edc 100644 --- a/22/windows-2019/Dockerfile +++ b/22/windows-2019/Dockerfile @@ -4,8 +4,8 @@ SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPref # PATH isn't actually set in the Docker image, so we have to set it from within the container RUN $newPath = ('C:\Program Files (x86)\GnuPG\bin;{0}' -f $env:PATH); \ - Write-Host ('Updating PATH: {0}' -f $newPath); \ - [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine) + Write-Host ('Updating PATH: {0}' -f $newPath); \ + [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine) # doing this first to share cache across versions more aggressively ENV NODE_VERSION 22.8.0 @@ -17,8 +17,8 @@ ENV GPG_CHECKSUM d2ac821ceacf9409ebcdb42ae330087ada30c732981f00b356f9c2f08fac4dc RUN Invoke-WebRequest $('https://www.gnupg.org/ftp/gcrypt/binary/gnupg-w32-{0}.exe' -f $env:GPG_VERSION) -OutFile 'gpg-installer.exe'; \ if ((Get-FileHash gpg-installer.exe -Algorithm sha256).Hash -ne $env:GPG_CHECKSUM) { Write-Error 'GPG checksum mismatch' }; \ - Start-Process -FilePath 'gpg-installer.exe' -ArgumentList '/S' -Wait; \ - gpg --version; + Start-Process -FilePath 'gpg-installer.exe' -ArgumentList '/S' -Wait; \ + gpg --version; RUN @( \ '4ED778F539E3634C779C87C6D7062848A1AB005C', \ @@ -56,12 +56,12 @@ COPY --from=installer C:/nodejs C:/nodejs COPY docker-entrypoint.ps1 C:/docker-entrypoint.ps1 RUN $newPath = ('C:\nodejs;{0}' -f $env:PATH); \ - Write-Host ('Updating PATH: {0}' -f $newPath); \ - [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine); \ - # Because we need to use it in the current session - $env:PATH = $newPath; \ - node --version; \ - npm --version; + Write-Host ('Updating PATH: {0}' -f $newPath); \ + [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine); \ + # Because we need to use it in the current session + $env:PATH = $newPath; \ + node --version; \ + npm --version; ENTRYPOINT [ "powershell.exe" , "C:/docker-entrypoint.ps1" ] diff --git a/22/windows-2019/docker-entrypoint.ps1 b/22/windows-2019/docker-entrypoint.ps1 index 87cbc8b77..016d737b7 100644 --- a/22/windows-2019/docker-entrypoint.ps1 +++ b/22/windows-2019/docker-entrypoint.ps1 @@ -5,12 +5,12 @@ $ErrorActionPreference = 'Stop' # 1. Contains a "-" # 2. Is NOT a recognized command # 3. Is a file that's NOT executable -if (($args[0] -like '*-') -or +if (($args[0] -like '*-') -or (!(Get-Command $args[0] -ErrorAction SilentlyContinue)) -or - (((Test-Path $args[0] -PathType Leaf)) -and -not ((Get-Item $args[0]).Attributes -band 'ReadOnly'))) { + (((Test-Path $args[0] -PathType Leaf)) -and -not ((Get-Item $args[0]).Attributes -band 'ReadOnly'))) { # Prepend 'node' to the argument list $args = @('node') + $args } # Execute the (potentially modified) command -& $args[0] $args[1..($args.Length-1)] \ No newline at end of file +& $args[0] $args[1..($args.Length-1)] diff --git a/22/windows-2022/Dockerfile b/22/windows-2022/Dockerfile index 2ed0e0f24..136e0baa0 100644 --- a/22/windows-2022/Dockerfile +++ b/22/windows-2022/Dockerfile @@ -4,8 +4,8 @@ SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPref # PATH isn't actually set in the Docker image, so we have to set it from within the container RUN $newPath = ('C:\Program Files (x86)\GnuPG\bin;{0}' -f $env:PATH); \ - Write-Host ('Updating PATH: {0}' -f $newPath); \ - [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine) + Write-Host ('Updating PATH: {0}' -f $newPath); \ + [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine) # doing this first to share cache across versions more aggressively ENV NODE_VERSION 22.8.0 @@ -17,8 +17,8 @@ ENV GPG_CHECKSUM d2ac821ceacf9409ebcdb42ae330087ada30c732981f00b356f9c2f08fac4dc RUN Invoke-WebRequest $('https://www.gnupg.org/ftp/gcrypt/binary/gnupg-w32-{0}.exe' -f $env:GPG_VERSION) -OutFile 'gpg-installer.exe'; \ if ((Get-FileHash gpg-installer.exe -Algorithm sha256).Hash -ne $env:GPG_CHECKSUM) { Write-Error 'GPG checksum mismatch' }; \ - Start-Process -FilePath 'gpg-installer.exe' -ArgumentList '/S' -Wait; \ - gpg --version; + Start-Process -FilePath 'gpg-installer.exe' -ArgumentList '/S' -Wait; \ + gpg --version; RUN @( \ '4ED778F539E3634C779C87C6D7062848A1AB005C', \ @@ -56,12 +56,12 @@ COPY --from=installer C:/nodejs C:/nodejs COPY docker-entrypoint.ps1 C:/docker-entrypoint.ps1 RUN $newPath = ('C:\nodejs;{0}' -f $env:PATH); \ - Write-Host ('Updating PATH: {0}' -f $newPath); \ - [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine); \ - # Because we need to use it in the current session - $env:PATH = $newPath; \ - node --version; \ - npm --version; + Write-Host ('Updating PATH: {0}' -f $newPath); \ + [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine); \ + # Because we need to use it in the current session + $env:PATH = $newPath; \ + node --version; \ + npm --version; ENTRYPOINT [ "powershell.exe" , "C:/docker-entrypoint.ps1" ] diff --git a/22/windows-2022/docker-entrypoint.ps1 b/22/windows-2022/docker-entrypoint.ps1 index 87cbc8b77..016d737b7 100644 --- a/22/windows-2022/docker-entrypoint.ps1 +++ b/22/windows-2022/docker-entrypoint.ps1 @@ -5,12 +5,12 @@ $ErrorActionPreference = 'Stop' # 1. Contains a "-" # 2. Is NOT a recognized command # 3. Is a file that's NOT executable -if (($args[0] -like '*-') -or +if (($args[0] -like '*-') -or (!(Get-Command $args[0] -ErrorAction SilentlyContinue)) -or - (((Test-Path $args[0] -PathType Leaf)) -and -not ((Get-Item $args[0]).Attributes -band 'ReadOnly'))) { + (((Test-Path $args[0] -PathType Leaf)) -and -not ((Get-Item $args[0]).Attributes -band 'ReadOnly'))) { # Prepend 'node' to the argument list $args = @('node') + $args } # Execute the (potentially modified) command -& $args[0] $args[1..($args.Length-1)] \ No newline at end of file +& $args[0] $args[1..($args.Length-1)] diff --git a/Dockerfile-windows.template b/Dockerfile-windows.template index 1f606327d..c99ee905c 100644 --- a/Dockerfile-windows.template +++ b/Dockerfile-windows.template @@ -4,8 +4,8 @@ SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPref # PATH isn't actually set in the Docker image, so we have to set it from within the container RUN $newPath = ('C:\Program Files (x86)\GnuPG\bin;{0}' -f $env:PATH); \ - Write-Host ('Updating PATH: {0}' -f $newPath); \ - [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine) + Write-Host ('Updating PATH: {0}' -f $newPath); \ + [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine) # doing this first to share cache across versions more aggressively ENV NODE_VERSION 0.0.0 @@ -16,9 +16,9 @@ ENV GPG_VERSION 2.4.5_20240307 ENV GPG_CHECKSUM d2ac821ceacf9409ebcdb42ae330087ada30c732981f00b356f9c2f08fac4dc1 RUN Invoke-WebRequest $('https://www.gnupg.org/ftp/gcrypt/binary/gnupg-w32-{0}.exe' -f $env:GPG_VERSION) -OutFile 'gpg-installer.exe'; \ - if ((Get-FileHash gpg-installer.exe -Algorithm sha256).Hash -ne $env:GPG_CHECKSUM) { Write-Error 'GPG checksum mismatch' }; \ - Start-Process -FilePath 'gpg-installer.exe' -ArgumentList '/S' -Wait; \ - gpg --version; + if ((Get-FileHash gpg-installer.exe -Algorithm sha256).Hash -ne $env:GPG_CHECKSUM) { Write-Error 'GPG checksum mismatch' }; \ + Start-Process -FilePath 'gpg-installer.exe' -ArgumentList '/S' -Wait; \ + gpg --version; RUN @( \ "${NODE_KEYS[@]}" @@ -45,12 +45,12 @@ COPY --from=installer C:/nodejs C:/nodejs COPY docker-entrypoint.ps1 C:/docker-entrypoint.ps1 RUN $newPath = ('C:\nodejs;{0}' -f $env:PATH); \ - Write-Host ('Updating PATH: {0}' -f $newPath); \ - [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine); \ - # Because we need to use it in the current session - $env:PATH = $newPath; \ - node --version; \ - npm --version; + Write-Host ('Updating PATH: {0}' -f $newPath); \ + [Environment]::SetEnvironmentVariable('PATH', $newPath, [EnvironmentVariableTarget]::Machine); \ + # Because we need to use it in the current session + $env:PATH = $newPath; \ + node --version; \ + npm --version; ENTRYPOINT [ "powershell.exe" , "C:/docker-entrypoint.ps1" ] diff --git a/architectures b/architectures index ad889beb8..095b09e17 100644 --- a/architectures +++ b/architectures @@ -5,4 +5,4 @@ arm32v7 alpine3.19,alpine3.20,bookworm,bookworm-slim,bullseye,bullseye-sl arm64v8 alpine3.19,alpine3.20,bookworm,bookworm-slim,bullseye,bullseye-slim i386 alpine3.19,alpine3.20 ppc64le alpine3.19,alpine3.20,bookworm,bookworm-slim,bullseye,bullseye-slim -s390x alpine3.19,alpine3.20,bookworm,bookworm-slim,bullseye,bullseye-slim \ No newline at end of file +s390x alpine3.19,alpine3.20,bookworm,bookworm-slim,bullseye,bullseye-slim diff --git a/docker-entrypoint.ps1 b/docker-entrypoint.ps1 index 87cbc8b77..016d737b7 100644 --- a/docker-entrypoint.ps1 +++ b/docker-entrypoint.ps1 @@ -5,12 +5,12 @@ $ErrorActionPreference = 'Stop' # 1. Contains a "-" # 2. Is NOT a recognized command # 3. Is a file that's NOT executable -if (($args[0] -like '*-') -or +if (($args[0] -like '*-') -or (!(Get-Command $args[0] -ErrorAction SilentlyContinue)) -or - (((Test-Path $args[0] -PathType Leaf)) -and -not ((Get-Item $args[0]).Attributes -band 'ReadOnly'))) { + (((Test-Path $args[0] -PathType Leaf)) -and -not ((Get-Item $args[0]).Attributes -band 'ReadOnly'))) { # Prepend 'node' to the argument list $args = @('node') + $args } # Execute the (potentially modified) command -& $args[0] $args[1..($args.Length-1)] \ No newline at end of file +& $args[0] $args[1..($args.Length-1)]