I have the below powershell
script which runs from jenkins
against windows server 2019
slave:
$sqlpackagepublish = Start-Process -FilePath sqlpackage.exe -ArgumentList '/Action:Publish','/SourceFile:"Database Services\bin\Release\Database Services.dacpac"',"/TargetConnectionString:""Data Source=${Env};Integrated Security=True;Persist Security Info=False;Pooling=False;MultipleActiveResultSets=False;Connect Timeout=60;Encrypt=False;TrustServerCertificate=False;Initial catalog=${Target}""","/p:BlockOnPossibleDataLoss=${Data_loss}" -wait -PassThru -Credential $Cred -RedirectStandardOutput sqlstdout.txt -RedirectStandardError sqlstderr.txt
$sqlpackagepublish.WaitForExit()
$sqlpackagepublish
if ($sqlpackagepublish.ExitCode -eq 0) {
Get-Content sqlstdout.txt
}
else {
echo "An error occurred"
Get-Content sqlstderr.txt
exit $sqlpackagepublish.ExitCode
}
But the deploy fails with no error in sqlstderr.txt
and no info in jenkins
log. any idea how I can debug it?