diff --git a/iac/build-release.ps1 b/iac/build-release.ps1 index 32dd2e5..665b5a0 100644 --- a/iac/build-release.ps1 +++ b/iac/build-release.ps1 @@ -1,3 +1,6 @@ +# Aktuellen Pfad auslesen +$currentDirectory = Get-Location + # Setzt das Arbeitsverzeichnis auf das Projektverzeichnis $projectPath = "../src/Cambooth/cambooth.app" # Anpassen an dein Projektverzeichnis Set-Location -Path $projectPath @@ -9,4 +12,7 @@ dotnet restore dotnet build --configuration Release # Erstellt eine veröffentlichungsfähige Version -dotnet publish --configuration Release -r win-x86 --output "publish" \ No newline at end of file +dotnet publish --configuration Release -r win-x86 --output "publish" + +# zu ursprünglichen pfad wechseln (für nachfolgende scripts wichtig) +Set-Location -Path $currentDirectory \ No newline at end of file diff --git a/iac/deploy_to_remote-pc.ps1 b/iac/deploy_to_remote-pc.ps1 index 34c8b27..80d0875 100644 --- a/iac/deploy_to_remote-pc.ps1 +++ b/iac/deploy_to_remote-pc.ps1 @@ -1,4 +1,6 @@ # --- Schritt 0: Erzeuge Build Dateien Write-Host "==> Build App as release ..." Invoke-Expression ".\build-release.ps1" -U:\HomeLab\Scripts\Windows\deploy_via_psexec.ps1 -RemoteComputer "Cambooth" -SourceFolder "../src/CamBooth/CamBooth.App/publish" -DestinationFolder "C:\Cambooth" -ProcessesToStop @("MyWPFApp") -ServicesToStop @("MyService") -AppExecutable "MyWPFApp.exe" -LocalUsername "cambooth\administrator" -LocalPassword "2013" + +# --- copy files to target client +U:\HomeLab\Scripts\Windows\deploy_via_psexec.ps1 -RemoteComputer "Cambooth" -LocalUsername "Administrator" -LocalPassword "2013" -EDSDKFolder "../misc/CanonBinaries" -SourceFolder "../src/CamBooth/CamBooth.App/publish" -DestinationFolder "C:\Cambooth" -ProcessesToStop @("MyWPFApp") -ServicesToStop @("MyService") -AppExecutable "MyWPFApp.exe"