From 85278e01bff15dd9b48eb3fded4cc9f3c978620c Mon Sep 17 00:00:00 2001 From: cproudlock Date: Wed, 13 May 2026 14:24:36 -0400 Subject: [PATCH] Run-ShopfloorSetup: fix Send-PxeStatus dot-source path Run-ShopfloorSetup.ps1 is copied by startnet.cmd to W:\Enrollment\ (root of Enrollment, NOT inside shopfloor-setup/). So $PSScriptRoot is W:\Enrollment\. The dot-source path was Join-Path $PSScriptRoot 'Shopfloor\lib\Send-PxeStatus.ps1' which resolves to W:\Enrollment\Shopfloor\lib\Send-PxeStatus.ps1 - that path does not exist. The actual file lands at W:\Enrollment\shopfloor-setup\Shopfloor\lib\ Send-PxeStatus.ps1 (xcopied by startnet from the Shopfloor share dir into the shopfloor-setup\ subdir). Test-Path returned false, dot-source silently skipped, Send-PxeStatus was never defined, every Report-Stage call no-op'd, no log file was written, no POSTs reached the dashboard. Symptom: bay reaches Windows desktop + runs Run-ShopfloorSetup but never appears on /imaging dashboard. C:\Logs\send-pxe-status.log does not exist on the bay. Fix: add the missing 'shopfloor-setup\' segment so the path resolves to the actual file location. 09-Setup-*.ps1 use a different relative path ('..\Shopfloor\lib\...') from inside the per-type dir and were unaffected. Monitor-IntuneProgress sits in Shopfloor\lib already and uses a sibling lookup - also fine. Co-Authored-By: Claude Opus 4.7 (1M context) --- playbook/shopfloor-setup/Run-ShopfloorSetup.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/playbook/shopfloor-setup/Run-ShopfloorSetup.ps1 b/playbook/shopfloor-setup/Run-ShopfloorSetup.ps1 index 9b97137..cca8216 100644 --- a/playbook/shopfloor-setup/Run-ShopfloorSetup.ps1 +++ b/playbook/shopfloor-setup/Run-ShopfloorSetup.ps1 @@ -29,7 +29,7 @@ Write-Host "" # Imaging-progress reporter. Posts coarse stage updates to the PXE webapp # at http://10.9.100.1:9009/imaging/status so the operator can watch # progress in a browser. Best-effort: failures never block imaging. -$pxeStatusLib = Join-Path $PSScriptRoot 'Shopfloor\lib\Send-PxeStatus.ps1' +$pxeStatusLib = Join-Path $PSScriptRoot 'shopfloor-setup\Shopfloor\lib\Send-PxeStatus.ps1' if (Test-Path $pxeStatusLib) { try { . $pxeStatusLib } catch { Write-Warning "Send-PxeStatus load failed: $_" } }