From 78d7a81e2b4f1df6ab16179c04b0029738020a91 Mon Sep 17 00:00:00 2001 From: Umair Date: Mon, 2 Jan 2023 21:51:51 +0000 Subject: [PATCH 1/2] Nvidia driver for g4dn s3 location changed and not in zip anymore --- GPUUpdaterTool.ps1 | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/GPUUpdaterTool.ps1 b/GPUUpdaterTool.ps1 index 23e4041..8cd9394 100644 --- a/GPUUpdaterTool.ps1 +++ b/GPUUpdaterTool.ps1 @@ -94,7 +94,7 @@ Function AWSPrivatedriver { $Bucket = "nvidia-gaming" $KeyPrefix = "windows/latest" $S3Objects = Get-S3Object -BucketName $Bucket -KeyPrefix $KeyPrefix -Region us-east-1 -ProfileName $profileName - $S3Objects.key | select-string -Pattern '.zip' + $S3Objects.key | select-string -Pattern '.exe' } elseif ($GPU -eq "G4ad") { $Bucket = "ec2-amd-windows-drivers" @@ -252,7 +252,7 @@ Function webDriver { AWSUseSavedCreds ParsecGPUUpdate AWSPrivatedriver -profileName ParsecGPUUpdate -GPU "G4dn"| Out-Null $G4WebDriver = AWSPrivatedriver -profileName ParsecGPUUpdate -GPU "G4dn" - $G4WebDriver.tostring().split('-')[1] + $G4WebDriver.tostring().split('/')[2] } Elseif((($gpu.Supported -eq "unOfficial") -and ($gpu.cloudprovider -eq "aws") -and ($gpu.Device_ID -eq "DEV_7362")) -eq $true){ AWSUseSavedCreds ParsecGPUUpdate @@ -410,6 +410,7 @@ function prepareEnvironment { function checkUpdates { queryGPU + Write-Host ($gpu | Out-String) -ForegroundColor Red #starts update if required if ($gpu.Update_Available -eq $true) { $app.success @@ -465,13 +466,7 @@ if ($($gpu.Device_ID -eq "DEV_1EB8") -or $($gpu.Device_ID -eq "DEV_15F8") -or $( function DownloadDriver { if((($gpu.Supported -eq "UnOfficial") -and ($gpu.cloudprovider -eq "aws") -and ($gpu.Device_ID -eq "DEV_1EB8")) -eq $true){ $S3Path = AWSPrivatedriver -profileName ParsecGPUUpdate -GPU "G4dn" - (New-Object System.Net.WebClient).DownloadFile($("https://nvidia-gaming.s3.amazonaws.com/" + $s3path), $($system.Path) + "\NVIDIA_" + $($gpu.web_driver) + ".zip") - Expand-Archive -Path ($($system.Path) + "\NVIDIA_" + $($gpu.web_driver) + ".zip") -DestinationPath "$($system.Path)\ExtractedGPUDriver\" - $extractedpath = Get-ChildItem -Path "$($system.Path)\ExtractedGPUDriver\Windows\" | Where-Object name -like '*win10*' | % name - Rename-Item -Path "$($system.Path)\ExtractedGPUDriver\Windows\$extractedpath" -NewName "NVIDIA_$($gpu.web_driver).exe" - Move-Item -Path "$($system.Path)\ExtractedGPUDriver\Windows\NVIDIA_$($gpu.web_driver).exe" -Destination $system.Path - remove-item "$($system.Path)\NVIDIA_$($gpu.web_driver).zip" - remove-item "$($system.Path)\ExtractedGPUDriver" -Recurse + (New-Object System.Net.WebClient).DownloadFile($("https://nvidia-gaming.s3.amazonaws.com/" + $s3path), $($system.Path) + "\NVIDIA_" + $($gpu.web_driver) + ".exe") (New-Object System.Net.WebClient).DownloadFile("https://nvidia-gaming.s3.amazonaws.com/GridSwCert-Archive/GridSwCert-Windows_2020_04.cert", "C:\Users\Public\Documents\GridSwCert.txt") ClearG4DNCredentials ParsecGPUUpdate } From ee1fda28eac4142165c0f84c2517bf177de4b6bd Mon Sep 17 00:00:00 2001 From: Umair Date: Mon, 2 Jan 2023 21:53:23 +0000 Subject: [PATCH 2/2] Removing debug line --- GPUUpdaterTool.ps1 | 1 - 1 file changed, 1 deletion(-) diff --git a/GPUUpdaterTool.ps1 b/GPUUpdaterTool.ps1 index 8cd9394..e9e70f1 100644 --- a/GPUUpdaterTool.ps1 +++ b/GPUUpdaterTool.ps1 @@ -410,7 +410,6 @@ function prepareEnvironment { function checkUpdates { queryGPU - Write-Host ($gpu | Out-String) -ForegroundColor Red #starts update if required if ($gpu.Update_Available -eq $true) { $app.success