Improve Windows provisioners stability (#733)

* Improve Install-CloudFoundryCli.ps1

* Improve Install-Go.ps1

* Improve Install-Kind.ps1

* Improve Install-MysqlCli.ps1

* Improve Install-Rust.ps1

* Improve Install-SQLPowerShellTools.ps1

* Improve Update-AndroidSDK.ps1

* Fix issue with resolve
This commit is contained in:
Maksim Petrov
2020-05-05 20:49:34 +03:00
committed by Mikhail Timofeev
parent 2cb2272923
commit 62f34bb9fa
7 changed files with 49 additions and 87 deletions

View File

@@ -3,10 +3,10 @@
## Desc: Install Mysql CLI
################################################################################
## Downloading mysql jar
$uri = 'https://dev.mysql.com/get/Downloads/MySQL-5.7/mysql-5.7.21-winx64.zip'
$mysqlPath = 'C:\mysql-5.7.21-winx64\bin'
$MysqlVersionName = "mysql-5.7.21-winx64"
$MysqlVersionUrl = "https://dev.mysql.com/get/Downloads/MySQL-5.7/${MysqlVersionName}.zip"
$MysqlPath = "C:\$MysqlVersionName\bin"
# Installing visual c++ redistibutable package.
$InstallerName = "vcredist_x64.exe"
@@ -19,13 +19,10 @@ Install-Binary -Url $InstallerURI -Name $InstallerName -ArgumentList $ArgumentLi
[Net.ServicePointManager]::SecurityProtocol = [Net.ServicePointManager]::SecurityProtocol -bor "Tls12"
# Get the latest mysql command line tools .
Invoke-WebRequest -UseBasicParsing -Uri $uri -OutFile mysql.zip
$mysqlArchPath = Start-DownloadWithRetry -Url $MysqlVersionUrl -Name "mysql.zip"
# Expand the zip
Expand-Archive -Path mysql.zip -DestinationPath "C:\" -Force
# Deleting zip folder
Remove-Item -Recurse -Force mysql.zip
Expand-Archive -Path $mysqlArchPath -DestinationPath "C:\" -Force
# Adding mysql in system environment path
Add-MachinePathItem $mysqlPath