chore(deployment): add Windows Service publish and install scripts
This commit is contained in:
23
publish-windows-service.ps1
Normal file
23
publish-windows-service.ps1
Normal file
@@ -0,0 +1,23 @@
|
||||
# publish-windows-service.ps1
|
||||
# Kullanim: .\publish-windows-service.ps1
|
||||
# Cikti: E:\Publish\MessagingService\WindowsService\
|
||||
|
||||
$project = "$PSScriptRoot\src\presentation\DigitalData.MessagingService.API\DigitalData.MessagingService.API.csproj"
|
||||
$output = "M:\App&Service\0 DD - Funktionsmodule\MessagingService\PreRelease\WindowsService\net8"
|
||||
|
||||
Write-Host "Publishing to $output ..." -ForegroundColor Cyan
|
||||
|
||||
dotnet publish $project `
|
||||
--configuration Release `
|
||||
--runtime win-x64 `
|
||||
--self-contained true `
|
||||
--output $output `
|
||||
-p:EnvironmentName=Production `
|
||||
-p:PublishSingleFile=false
|
||||
|
||||
if ($LASTEXITCODE -eq 0) {
|
||||
Write-Host "Done. Files at: $output" -ForegroundColor Green
|
||||
} else {
|
||||
Write-Host "Publish FAILED." -ForegroundColor Red
|
||||
exit 1
|
||||
}
|
||||
Reference in New Issue
Block a user