From 117a9f17f9469f7cde4e787c11ef9956df1361a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=90=D0=BD=D0=B4=D1=80=D0=B5=D0=B9=20=D0=9A=D0=B0=D0=B7?= =?UTF-8?q?=D0=B0=D0=BD=D1=86=D0=B5=D0=B2?= Date: Tue, 17 Jun 2025 22:48:49 +0500 Subject: [PATCH] =?UTF-8?q?[Moby]=20=D0=A4=D0=B8=D0=BA=D1=81=20=D1=81?= =?UTF-8?q?=D0=B1=D0=BE=D1=80=D0=BA=D0=B8=20=D0=B8=20README?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Dockerfile | 15 +++++++++++++++ README.md | 37 +++++++++++++++++++++++++++++++++++++ 2 files changed, 52 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..d3eba82 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,15 @@ +FROM mcr.microsoft.com/windows/servercore:ltsc2019 + +RUN curl -SL --output vs_buildtools.exe https://aka.ms/vs/17/release/vs_buildtools.exe \ + && (start /w vs_buildtools.exe \ + --quiet --wait --norestart --nocache \ + --installPath "%ProgramFiles(x86)%\Microsoft Visual Studio\2022\BuildTools" \ + --noUpdateInstaller \ + --add Microsoft.Component.MSBuild \ + --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 \ + --add Microsoft.VisualStudio.Component.VC.DiagnosticTools \ + --add Microsoft.VisualStudio.Component.Windows11SDK.22261 \ + --add Microsoft.VisualStudio.Component.VC.Redist.14.latest \ + --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Core \ + || IF "%ERRORLEVEL%"=="3010" EXIT 0) \ + && del /q vs_buildtools.exe \ No newline at end of file diff --git a/README.md b/README.md index b4917a4..5cb2996 100644 --- a/README.md +++ b/README.md @@ -67,4 +67,41 @@ Server: docker pull mcr.microsoft.com/windows/servercore:ltsc2025 docker pull mcr.microsoft.com/windows/servercore:ltsc2022 docker pull mcr.microsoft.com/windows/servercore:ltsc2019 +``` + +5. Для подготовки базового образа сборка должна быть на `ltsc2019` со следующими параметрами: +``` +FROM mcr.microsoft.com/windows/servercore:ltsc2019 + +RUN curl -SL --output vs_buildtools.exe https://aka.ms/vs/17/release/vs_buildtools.exe \ + && (start /w vs_buildtools.exe \ + --quiet --wait --norestart --nocache \ + --installPath "%ProgramFiles(x86)%\Microsoft Visual Studio\2022\BuildTools" \ + --noUpdateInstaller \ + --add Microsoft.Component.MSBuild \ + --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 \ + --add Microsoft.VisualStudio.Component.VC.DiagnosticTools \ + --add Microsoft.VisualStudio.Component.Windows11SDK.22261 \ + --add Microsoft.VisualStudio.Component.VC.Redist.14.latest \ + --add Microsoft.VisualStudio.ComponentGroup.NativeDesktop.Core \ + || IF "%ERRORLEVEL%"=="3010" EXIT 0) \ + && del /q vs_buildtools.exe +``` + +6. В случае ошибки по `hcsshim::ImportLayer failed in Win32: The system cannot find the path specified. (0x3)` +требуется выполнить конфигурацию `dockerd` в `%programdata%\docker\config\daemon.json` + +Пример: +``` +{ +"hosts": [ + "npipe://" + ], +"experimental": false, +"storage-opts": [ +"size=300GB" +], +"data-root": "D:\\docker-root" +} + ``` \ No newline at end of file