-
Notifications
You must be signed in to change notification settings - Fork 335
/
Dockerfile
28 lines (25 loc) · 1.35 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# escape=`
FROM mcr.microsoft.com/windows/servercore:ltsc2019-amd64
ENV `
# Enable detection of running in a container
COMPLUS_RUNNING_IN_CONTAINER=1 `
COMPLUS_NGenProtectedProcess_FeatureEnabled=0
RUN `
# Install .NET Fx 4.8
curl -fSLo dotnet-framework-installer.exe https://download.visualstudio.microsoft.com/download/pr/2d6bb6b2-226a-4baa-bdec-798822606ff1/8494001c276a4b96804cde7829c04d7f/ndp48-x86-x64-allos-enu.exe `
&& .\dotnet-framework-installer.exe /q `
&& del .\dotnet-framework-installer.exe `
&& powershell Remove-Item -Force -Recurse ${Env:TEMP}\* `
`
# Apply latest patch
&& curl -fSLo patch.msu https://catalog.s.download.windowsupdate.com/d/msdownload/update/software/updt/2024/10/windows10.0-kb5046269-x64-ndp48_ffaedfbf319b1822620e751996e1d9ba0653b2f6.msu `
&& mkdir patch `
&& expand patch.msu patch -F:* `
&& del /F /Q patch.msu `
&& dism /Online /Quiet /Add-Package /PackagePath:C:\patch\windows10.0-kb5046269-x64-ndp48.cab `
&& rmdir /S /Q patch `
`
# ngen .NET Fx
&& %windir%\Microsoft.NET\Framework64\v4.0.30319\ngen uninstall "Microsoft.Tpm.Commands, Version=10.0.0.0, Culture=Neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=amd64" `
&& %windir%\Microsoft.NET\Framework64\v4.0.30319\ngen update `
&& %windir%\Microsoft.NET\Framework\v4.0.30319\ngen update