From e74786f7403acafb0379ea35fe3c04c4ebc5b4f0 Mon Sep 17 00:00:00 2001 From: Aleksandr Chebotov Date: Thu, 20 Jan 2022 10:29:45 +0300 Subject: [PATCH] Wait for Windows Updates --- images/win/windows2016.json | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/images/win/windows2016.json b/images/win/windows2016.json index e2aaa2d66a37..eeb8973a2401 100644 --- a/images/win/windows2016.json +++ b/images/win/windows2016.json @@ -258,11 +258,15 @@ }, { "type": "windows-restart", + "check_registry": true, + "restart_check_command": "powershell -command \"& {if ((-not (Get-Process TiWorker.exe -ErrorAction SilentlyContinue)) -and (-not [System.Environment]::HasShutdownStarted) ) { Write-Output 'Restart complete' }}\"", "restart_timeout": "30m" }, { "type": "powershell", + "pause_before": "2m", "scripts": [ + "{{ template_dir }}/scripts/Installers/Wait-WindowsUpdatesForInstall.ps1", "{{ template_dir }}/scripts/Tests/RunAll-Tests.ps1" ] },