diff --git a/Updater/Update-Service.ps1 b/Updater/Update-Service.ps1 index 4cf7d0a8303cdd2a3cb76d57484d040d3e708704..41ef792651fd8a47fde12f37056bfafb42d0d79e 100644 --- a/Updater/Update-Service.ps1 +++ b/Updater/Update-Service.ps1 @@ -298,11 +298,13 @@ function Update-ServiceBinaries { function Upload-LogFiles { + $Dest = "$($UploadPathLogs)\$($env:COMPUTERNAME)" + New-Item -Force -Type Directory $Dest try { Copy-Item -Force -ErrorAction Stop ` -Path "$($LogPath)\service.log" ` - -Destination $UploadPathLogs - Log-Debug "Uploaded logfile to [$($UploadPathLogs)]." + -Destination $Dest + Log-Debug "Uploaded logfile to [$($Dest)]." } catch { Log-Warning "Uploading logfile FAILED!`n$($_.Exception.Message)" @@ -418,7 +420,7 @@ $UpdPathConfig = "$($UpdateSourcePath)\Configs\$($env:COMPUTERNAME)" $UpdPathConfigCommon = "$($UpdateSourcePath)\Configs\_COMMON_" $UpdPathMarkerFiles = "$($UpdateSourcePath)\Service\UpdateMarkers" $UpdPathBinaries = "$($UpdateSourcePath)\Service\Binaries" -$UploadPathLogs = "$($UpdateSourcePath)\Logs\$($env:COMPUTERNAME)" +$UploadPathLogs = "$($UpdateSourcePath)\Logs" Exit-IfDirMissing $InstallationPath "installation" Exit-IfDirMissing $LogPath "log files"