From ded4e461b0193622f8bac51fbd43951ab0b8c39d Mon Sep 17 00:00:00 2001 From: Luke Fritts Date: Fri, 10 Nov 2023 10:38:32 -0500 Subject: [PATCH] [Windows] Set user agent header to get mysql patch version (#8773) --- images/win/scripts/Installers/Install-MysqlCli.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/images/win/scripts/Installers/Install-MysqlCli.ps1 b/images/win/scripts/Installers/Install-MysqlCli.ps1 index 079ac5b51..a05b56cd3 100644 --- a/images/win/scripts/Installers/Install-MysqlCli.ps1 +++ b/images/win/scripts/Installers/Install-MysqlCli.ps1 @@ -16,7 +16,7 @@ Install-Binary -Url $InstallerURI -Name $InstallerName -ArgumentList $ArgumentLi $MysqlVersionMajorMinor = $MysqlVersion.ToString(2) if ($MysqlVersion.Build -lt 0) { - $MysqlVersion = (Invoke-RestMethod -Uri "https://dev.mysql.com/downloads/mysql/${MysqlVersionMajorMinor}.html" -Headers @{'Accept'='text/html'} | + $MysqlVersion = (Invoke-RestMethod -Uri "https://dev.mysql.com/downloads/mysql/${MysqlVersionMajorMinor}.html" -Headers @{ 'User-Agent'='curl/8.4.0' } | Select-String -Pattern "${MysqlVersionMajorMinor}\.\d+").Matches.Value }