mirror of
https://github.com/actions/runner-images-sangeeth.git
synced 2025-12-20 06:29:50 +00:00
added some unneccesary things
This commit is contained in:
@@ -61,9 +61,7 @@ function Start-Installer {
|
|||||||
$installerUrl = "https://go.microsoft.com/fwlink/?linkid=866658"
|
$installerUrl = "https://go.microsoft.com/fwlink/?linkid=866658"
|
||||||
$downloadPath = "${env:Temp}"
|
$downloadPath = "${env:Temp}"
|
||||||
$setupPath = Join-Path $downloadPath "SQLEXPR_x64_ENU"
|
$setupPath = Join-Path $downloadPath "SQLEXPR_x64_ENU"
|
||||||
#Set default location for installation process
|
|
||||||
Set-Location -Path $downloadPath
|
Set-Location -Path $downloadPath
|
||||||
#Download installer for SQL Express and return path to it
|
|
||||||
$installerPath = Start-DownloadWithRetry -Url "https://go.microsoft.com/fwlink/?linkid=866658" -Name SQL2019-SSEI-Expr.exe
|
$installerPath = Start-DownloadWithRetry -Url "https://go.microsoft.com/fwlink/?linkid=866658" -Name SQL2019-SSEI-Expr.exe
|
||||||
Download-FullSQLPackage -InstallerPath $installerPath
|
Download-FullSQLPackage -InstallerPath $installerPath
|
||||||
Unpack-SQLInstaller -InstallPath "$setupPath.exe"
|
Unpack-SQLInstaller -InstallPath "$setupPath.exe"
|
||||||
|
|||||||
@@ -27,9 +27,11 @@ function Test-SqlConnection {
|
|||||||
$sqlConnection.Open()
|
$sqlConnection.Open()
|
||||||
Write-Host -Object "Connection to database: {0} was successful. Version of SQL Express is: {1}" -f $sqlConnection.Database,$sqlConnection.ServerVersion
|
Write-Host -Object "Connection to database: {0} was successful. Version of SQL Express is: {1}" -f $sqlConnection.Database,$sqlConnection.ServerVersion
|
||||||
return $sqlConnection.ServerVersion
|
return $sqlConnection.ServerVersion
|
||||||
|
|
||||||
} catch {
|
} catch {
|
||||||
Write-Host -Object "Connection to SQL Express cannot be established."
|
Write-Host -Object "Connection to SQL Express cannot be established."
|
||||||
exit 1
|
exit 1
|
||||||
|
|
||||||
} finally {
|
} finally {
|
||||||
## Close the connection when we're done
|
## Close the connection when we're done
|
||||||
$sqlConnection.Close()
|
$sqlConnection.Close()
|
||||||
|
|||||||
Reference in New Issue
Block a user