[windows] Add filters to Java assets API call (#13808)
This commit is contained in:
@@ -53,7 +53,7 @@ function Install-JavaJDK {
|
||||
)
|
||||
|
||||
# Get Java version from api
|
||||
$assetUrl = Invoke-RestMethod -Uri "https://api.adoptium.net/v3/assets/latest/${JDKVersion}/hotspot" -Headers @{"Accept" = "application/json"}
|
||||
$assetUrl = Invoke-RestMethod -Uri "https://api.adoptium.net/v3/assets/latest/${JDKVersion}/hotspot?architecture=${Architecture}&os=windows" -Headers @{"Accept" = "application/json"}
|
||||
|
||||
$asset = $assetUrl | Where-Object {
|
||||
$_.binary.os -eq "windows" `
|
||||
|
||||
Reference in New Issue
Block a user