25 lines
507 B
PowerShell
25 lines
507 B
PowerShell
param(
|
|
[switch]$SkipHealthCheck
|
|
)
|
|
|
|
$ErrorActionPreference = "Stop"
|
|
|
|
$RepoRoot = Split-Path -Parent $MyInvocation.MyCommand.Path
|
|
$DelegateScript = Join-Path $RepoRoot "scripts\catalogsync\deploy_to_nas.ps1"
|
|
|
|
if (-not (Test-Path -LiteralPath $DelegateScript)) {
|
|
throw "Deploy script not found: $DelegateScript"
|
|
}
|
|
|
|
$arguments = @(
|
|
"-ExecutionPolicy", "Bypass",
|
|
"-File", $DelegateScript
|
|
)
|
|
|
|
if ($SkipHealthCheck) {
|
|
$arguments += "-SkipHealthCheck"
|
|
}
|
|
|
|
powershell @arguments
|
|
exit $LASTEXITCODE
|