test(validation): #800 gate re-run on windev with the fixed isolation installer, both PowerShell hosts
v2-ci / unit-tests (push) Has been cancelled
v2-ci / unit-tests (push) Has been cancelled
Re-runs only the ScriptWorker step on windev (master da948e5f, SDK 2.0.1, 16 vCPUs): install as the OtOpcUaHost service,
repo Install-ScriptWorkerIsolation.ps1 applied/re-applied/uninstalled twice under pwsh 7 and Windows PowerShell 5.1,
restricted worker, pipe refuses the admin, runner Healthy, strict-peer/API-key matrix on, then cleanup. The harness drops
-PatchedIsolation, gains -PrepareFrom candidate and -ApplyHost, and suffixes the isolation evidence with -Label.
Claude-Session: https://claude.ai/code/session_01GT67ACmpMR7b9LGRPLijMi
This commit is contained in:
@@ -37,9 +37,10 @@ $g = 'C:\OtOpcUa800\upload\Invoke-ServiceGate.ps1'
|
||||
& $g -Phase Upgrade # backup, stage separately, carry appsettings/pki/data/logs with /COPYALL, swap
|
||||
& $g -Phase Boot -Label c1; & $g -Phase Checks -Label c1; & $g -Phase Stop -Label c1
|
||||
& $g -Phase Boot -Label c2; & $g -Phase Checks -Label c2; & $g -Phase Stop -Label c2
|
||||
& $g -Phase IsolationInstall -PatchedIsolation # see lmxopcua#883; drop the switch once the repo installer is fixed
|
||||
& $g -Phase IsolationInstall -Label s1 -ApplyHost pwsh # apply with 7, re-apply with 5.1 and 7
|
||||
& $g -Phase Boot -Label c3; & $g -Phase Checks -Label c3; & $g -Phase IsolationVerify -Label c3; & $g -Phase Stop -Label c3
|
||||
& $g -Phase IsolationUninstall -PatchedIsolation
|
||||
& $g -Phase IsolationUninstall -Label s1 -ApplyHost pwsh
|
||||
# Optional second pass with the hosts swapped (apply with 5.1): IsolationInstall/Verify/Uninstall -Label s2 -ApplyHost powershell.exe
|
||||
& $g -Phase Rollback
|
||||
& $g -Phase Boot -Label r1; & $g -Phase Checks -Label r1 -BaselineServer; & $g -Phase Stop -Label r1
|
||||
& $g -Phase Compare -Label b1,c1,c2,c3,r1
|
||||
@@ -51,6 +52,10 @@ at the first error. A `Checks` failure lists the failing cases by name. Secrets
|
||||
`<Root>\private\secrets.json`, which only SYSTEM and Administrators can read. Every output and log is checked against every
|
||||
task secret, and the evidence keeps only the redacted copies and the occurrence counts.
|
||||
|
||||
**Re-running only the isolation step.** `-Phase Prepare -PrepareFrom candidate` installs the candidate directly (no baseline,
|
||||
upgrade or rollback), so `baseline-host` and `install-baseline` are not needed:
|
||||
`Prepare`, `Boot b0 -AllowNotReady`, `Stop b0`, `Seed`, `Trust`, `Boot/Checks/Stop c1`, then the isolation phases, then `Cleanup`.
|
||||
|
||||
## What the checks mean
|
||||
|
||||
- **Strict channel.** These are gating cases. The probe's peer auto-accept is off. A trusted client gets a Basic256Sha256 Sign
|
||||
@@ -66,11 +71,14 @@ task secret, and the evidence keeps only the redacted copies and the occurrence
|
||||
key and the SDK 1.5 CLI with the 65-character key remain the positive controls.
|
||||
- **CLIs.** The CLI that matches each SDK line reads `ServerStatus` over SignAndEncrypt with an API key. The CLIs auto-accept
|
||||
the server certificate by design, so these reads do not count as strict-peer coverage.
|
||||
- **ScriptWorker isolation.** `IsolationInstall`/`IsolationUninstall` run `Install-ScriptWorkerIsolation.ps1`. The script
|
||||
runs once under PowerShell 7 and once under Windows PowerShell 5.1, so both must work. The script's dry run happens first.
|
||||
Without `-PatchedIsolation` the repository copy is used, and that copy fails on both hosts (lmxopcua#883). With
|
||||
`-PatchedIsolation` it uses `<Root>\upload\install-candidate-patched`, which is the repository copy plus
|
||||
`evidence/2026-11-12-windev/isolation-installer-883.diff`. `IsolationVerify` needs the service running. It checks:
|
||||
- **ScriptWorker isolation.** `IsolationInstall`/`IsolationUninstall` run `Install-ScriptWorkerIsolation.ps1` from
|
||||
`<Root>\upload\install-candidate`. The script runs under PowerShell 7 and Windows PowerShell 5.1, so both must work:
|
||||
`-ApplyHost` picks the host that applies (and rolls back first), the other host re-applies (every step must report
|
||||
`unchanged`) and does the second, idempotent uninstall. The dry run happens first, on both hosts. The first run of this gate
|
||||
(2026-11-12, `evidence/2026-11-12-windev/`) found the installer failing on both hosts (lmxopcua#883); it was exercised there
|
||||
with `isolation-installer-883.diff`, which is now merged. `scripts/install/tests/Test-ScriptWorkerIsolation.Windows.ps1` is the
|
||||
standalone Windows-executed apply / re-apply / uninstall test (scratch names, no OtOpcUaHost needed). `IsolationVerify` needs
|
||||
the service running. It checks:
|
||||
- worker processes are children of the host and run under a restricted token;
|
||||
- the elevated administrator is refused on the worker pipe;
|
||||
- `script-runner` health and the PE cache.
|
||||
|
||||
Reference in New Issue
Block a user