Mesa (master): CI: windows: split the layers to meet new registry requirements

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Fri Jan 29 18:12:27 UTC 2021


Module: Mesa
Branch: master
Commit: a69ab2ae3693fd817d6ba0d0345aca6931a6c5fd
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=a69ab2ae3693fd817d6ba0d0345aca6931a6c5fd

Author: Benjamin Tissoires <benjamin.tissoires at gmail.com>
Date:   Wed Jan 27 15:17:28 2021 +0100

CI: windows: split the layers to meet new registry requirements

The new registry caching in place for registry.fd.o can not handle layers
bigger than 5 GB. The last layer we used to build on windows was 5.2 GB,
meaning that the upload would fail.

Split the layers by calling multiple `RUN`, hoping that the size will be
roughly split between those steps if we have a special layer for VS2019.

Reviewed-by: Erik Faye-Lund <erik.faye-lund at collabora.com>
Reviewed-by: Daniel Stone <daniel at fooishbar.org>
Signed-off-by: Benjamin Tissoires <benjamin.tissoires at gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8740>

---

 .gitlab-ci.yml                          |  2 +-
 .gitlab-ci/windows/Dockerfile           |  3 +++
 .gitlab-ci/windows/mesa_deps.ps1        | 16 ----------------
 .gitlab-ci/windows/mesa_deps_vs2019.ps1 | 18 ++++++++++++++++++
 4 files changed, 22 insertions(+), 17 deletions(-)

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 70990481ef1..13b7baa53e6 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -445,7 +445,7 @@ armhf_test:
 
 .windows-docker-vs2019:
   variables:
-    WINDOWS_TAG: "2020-12-02"
+    WINDOWS_TAG: "2021-01-27.1"
     WINDOWS_IMAGE: "$CI_REGISTRY_IMAGE/windows/x64_build:${WINDOWS_TAG}-${MESA_TEMPLATES_COMMIT}"
     WINDOWS_UPSTREAM_IMAGE: "$CI_REGISTRY/$FDO_UPSTREAM_REPO/windows/x64_build:${WINDOWS_TAG}-${MESA_TEMPLATES_COMMIT}"
 
diff --git a/.gitlab-ci/windows/Dockerfile b/.gitlab-ci/windows/Dockerfile
index 02d9584e4a6..430112ff1a4 100644
--- a/.gitlab-ci/windows/Dockerfile
+++ b/.gitlab-ci/windows/Dockerfile
@@ -6,5 +6,8 @@ FROM mcr.microsoft.com/windows:1809
 SHELL ["powershell", "-ExecutionPolicy", "RemoteSigned", "-Command", "$ErrorActionPreference = 'Stop';"]
 ENV ErrorActionPreference='Stop'
 
+COPY mesa_deps_vs2019.ps1 C:\
+RUN C:\mesa_deps_vs2019.ps1
+
 COPY mesa_deps.ps1 C:\
 RUN C:\mesa_deps.ps1
diff --git a/.gitlab-ci/windows/mesa_deps.ps1 b/.gitlab-ci/windows/mesa_deps.ps1
index 549cc91b573..58efe95ec44 100644
--- a/.gitlab-ci/windows/mesa_deps.ps1
+++ b/.gitlab-ci/windows/mesa_deps.ps1
@@ -43,22 +43,6 @@ if (!$?) {
 # downloads so must be done after Chocolatey use
 [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12;
 
-# VS16.x is 2019
-$msvc_2019_url = 'https://aka.ms/vs/16/release/vs_buildtools.exe'
-
-Get-Date
-Write-Host "Downloading Visual Studio 2019 build tools"
-Invoke-WebRequest -Uri $msvc_2019_url -OutFile C:\vs_buildtools.exe
-
-Get-Date
-Write-Host "Installing Visual Studio 2019"
-Start-Process -NoNewWindow -Wait C:\vs_buildtools.exe -ArgumentList '--wait --quiet --norestart --nocache --installPath C:\BuildTools --add Microsoft.VisualStudio.Workload.VCTools --add Microsoft.VisualStudio.Workload.NativeDesktop --add Microsoft.VisualStudio.Component.VC.ATL --add Microsoft.VisualStudio.Component.VC.ATLMFC --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.Component.Graphics.Tools --add Microsoft.VisualStudio.Component.Windows10SDK.18362 --includeRecommended'
-if (!$?) {
-  Write-Host "Failed to install Visual Studio tools"
-  Exit 1
-}
-Remove-Item C:\vs_buildtools.exe -Force
-
 Get-Date
 Write-Host "Cloning LLVM master"
 git clone -b master --depth=1 https://github.com/llvm/llvm-project llvm-project
diff --git a/.gitlab-ci/windows/mesa_deps_vs2019.ps1 b/.gitlab-ci/windows/mesa_deps_vs2019.ps1
new file mode 100644
index 00000000000..d1da176d9bd
--- /dev/null
+++ b/.gitlab-ci/windows/mesa_deps_vs2019.ps1
@@ -0,0 +1,18 @@
+# we want more secure TLS 1.2 for most things
+[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12;
+
+# VS16.x is 2019
+$msvc_2019_url = 'https://aka.ms/vs/16/release/vs_buildtools.exe'
+
+Get-Date
+Write-Host "Downloading Visual Studio 2019 build tools"
+Invoke-WebRequest -Uri $msvc_2019_url -OutFile C:\vs_buildtools.exe
+
+Get-Date
+Write-Host "Installing Visual Studio 2019"
+Start-Process -NoNewWindow -Wait C:\vs_buildtools.exe -ArgumentList '--wait --quiet --norestart --nocache --installPath C:\BuildTools --add Microsoft.VisualStudio.Workload.VCTools --add Microsoft.VisualStudio.Workload.NativeDesktop --add Microsoft.VisualStudio.Component.VC.ATL --add Microsoft.VisualStudio.Component.VC.ATLMFC --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.Component.Graphics.Tools --add Microsoft.VisualStudio.Component.Windows10SDK.18362 --includeRecommended'
+if (!$?) {
+  Write-Host "Failed to install Visual Studio tools"
+  Exit 1
+}
+Remove-Item C:\vs_buildtools.exe -Force



More information about the mesa-commit mailing list