Patch/Sample/OnBeforeImportPatch.ps1
# $DatabaseServerInstance - full name of SQL server # $DatabaseName - database name # $NavServerName - physical name of server where nav is installed # $NavServerInstance - name of the nav server instance # $NavManagementPort - number of nav server management port . Setup-UpgradeTask ` -TaskName "Task executed before patch imported" ` -ScriptBlock { # Write plugin code here # Use variables available in Start-Upgrade function of Install-Release.ps1 script # e.g. Write-Warning "Variables available $DatabaseServer $DatabaseName $NavServerName $NavServerInstance $NavManagementPort" } | % { $UpgradeTasks.Add($_.Statistics, $_.ScriptBlock) } |