Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Added link to gpg key and remove verbose logging
  • Loading branch information
zZHorizonZz committed Sep 5, 2024
commit 47843c9f07e4c350f86d73a0edf7afaf7d273992
16 changes: 8 additions & 8 deletions 22/windows-2019/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@ 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
ENV NODE_CHECKSUM d6e1c4fca93997224cac0bec09b4201aa018f50171d38c6b85abe483012839c9

# Version and checksum of the GPG installer (Source: https://lists.gnupg.org/pipermail/gnupg-announce/2024q3/000484.html)
# Version and checksum of the GPG installer (Source: https://www.gnupg.org/download/integrity_check.html)
ENV GPG_VERSION 2.4.5_20240307
ENV GPG_CHECKSUM d2ac821ceacf9409ebcdb42ae330087ada30c732981f00b356f9c2f08fac4dc1

Expand All @@ -34,9 +34,9 @@ RUN @( \
'A363A499291CBBC940DD62E41F10027AF002F8B0', \
'CC68F5A3106FF448322E48ED27F5E38D5B0A215F' \
) | foreach { \
gpg --batch --keyserver hkps://keys.openpgp.org --verbose --recv-keys $_ ; \
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys $_ ; \
if (-not $?) { \
gpg --batch --keyserver keyserver.ubuntu.com --verbose --recv-keys $_ ; \
gpg --batch --keyserver keyserver.ubuntu.com --recv-keys $_ ; \
} \
} ; \
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 ; \
Expand All @@ -53,8 +53,8 @@ FROM mcr.microsoft.com/windows/servercore:ltsc2019 as runner
SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]

RUN $newPath = ('C:\nodejs;{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)

COPY --from=installer C:/nodejs C:/nodejs

Expand All @@ -63,6 +63,6 @@ ENTRYPOINT [ "powershell.exe" , "C:/docker-entrypoint.ps1" ]

# Smoke test
RUN node --version; \
npm --version;
npm --version;

CMD [ "node.exe" ]
16 changes: 8 additions & 8 deletions 22/windows-2022/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@ 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
ENV NODE_CHECKSUM d6e1c4fca93997224cac0bec09b4201aa018f50171d38c6b85abe483012839c9

# Version and checksum of the GPG installer (Source: https://lists.gnupg.org/pipermail/gnupg-announce/2024q3/000484.html)
# Version and checksum of the GPG installer (Source: https://www.gnupg.org/download/integrity_check.html)
ENV GPG_VERSION 2.4.5_20240307
ENV GPG_CHECKSUM d2ac821ceacf9409ebcdb42ae330087ada30c732981f00b356f9c2f08fac4dc1

Expand All @@ -34,9 +34,9 @@ RUN @( \
'A363A499291CBBC940DD62E41F10027AF002F8B0', \
'CC68F5A3106FF448322E48ED27F5E38D5B0A215F' \
) | foreach { \
gpg --batch --keyserver hkps://keys.openpgp.org --verbose --recv-keys $_ ; \
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys $_ ; \
if (-not $?) { \
gpg --batch --keyserver keyserver.ubuntu.com --verbose --recv-keys $_ ; \
gpg --batch --keyserver keyserver.ubuntu.com --recv-keys $_ ; \
} \
} ; \
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 ; \
Expand All @@ -53,8 +53,8 @@ FROM mcr.microsoft.com/windows/servercore:ltsc2022 as runner
SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]

RUN $newPath = ('C:\nodejs;{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)

COPY --from=installer C:/nodejs C:/nodejs

Expand All @@ -63,6 +63,6 @@ ENTRYPOINT [ "powershell.exe" , "C:/docker-entrypoint.ps1" ]

# Smoke test
RUN node --version; \
npm --version;
npm --version;

CMD [ "node.exe" ]
16 changes: 8 additions & 8 deletions Dockerfile-windows.template
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@ 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
ENV NODE_CHECKSUM CHECKSUM_x64
Comment thread
zZHorizonZz marked this conversation as resolved.

# Version and checksum of the GPG installer (Source: https://lists.gnupg.org/pipermail/gnupg-announce/2024q3/000484.html)
# Version and checksum of the GPG installer (Source: https://www.gnupg.org/download/integrity_check.html)
ENV GPG_VERSION 2.4.5_20240307
ENV GPG_CHECKSUM d2ac821ceacf9409ebcdb42ae330087ada30c732981f00b356f9c2f08fac4dc1

Expand All @@ -23,9 +23,9 @@ RUN Invoke-WebRequest $('https://www.gnupg.org/ftp/gcrypt/binary/gnupg-w32-{0}.e
RUN @( \
"${NODE_KEYS[@]}"
) | foreach { \
gpg --batch --keyserver hkps://keys.openpgp.org --verbose --recv-keys $_ ; \
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys $_ ; \
if (-not $?) { \
gpg --batch --keyserver keyserver.ubuntu.com --verbose --recv-keys $_ ; \
gpg --batch --keyserver keyserver.ubuntu.com --recv-keys $_ ; \
} \
} ; \
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 ; \
Expand All @@ -42,8 +42,8 @@ FROM mcr.microsoft.com/windows/servercore:version as runner
SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]

RUN $newPath = ('C:\nodejs;{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)

COPY --from=installer C:/nodejs C:/nodejs

Expand All @@ -52,6 +52,6 @@ ENTRYPOINT [ "powershell.exe" , "C:/docker-entrypoint.ps1" ]

# Smoke test
RUN node --version; \
npm --version;
npm --version;
Comment thread
zZHorizonZz marked this conversation as resolved.
Outdated

CMD [ "node.exe" ]