From d5cf2554438060524a1982012ee521d98922526d Mon Sep 17 00:00:00 2001 From: cproudlock Date: Thu, 6 Aug 2026 16:12:41 -0400 Subject: [PATCH] Kiosk bootstrap: look for the installer where staging actually puts it The bootstrap looked for C:\Enrollment\kiosk\Install-ShopdbKiosk.ps1, but startnet copies the type-specific tree to C:\Enrollment\shopfloor-setup\gea-shopfloor-display\ - so the payload lands beside the bootstrap, not under C:\Enrollment. As written it would have logged "Installer not staged" on every 15-minute cycle and never installed anything, with no error anywhere. Exactly the silent-failure shape this whole day has been about, and it would have looked like the API being unreachable. Resolves via a -KioskRoot parameter defaulting to kiosk\ next to the script, so the bootstrap and its payload travel together regardless of where the tree is staged. display-type.txt still comes from EnrollmentRoot, which is correct - that one really is at C:\Enrollment. --- .../Install-ShopdbKiosk-WhenOnline.ps1 | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/playbook/shopfloor-setup/gea-shopfloor-display/Install-ShopdbKiosk-WhenOnline.ps1 b/playbook/shopfloor-setup/gea-shopfloor-display/Install-ShopdbKiosk-WhenOnline.ps1 index 7ad86ca..f9efbf2 100644 --- a/playbook/shopfloor-setup/gea-shopfloor-display/Install-ShopdbKiosk-WhenOnline.ps1 +++ b/playbook/shopfloor-setup/gea-shopfloor-display/Install-ShopdbKiosk-WhenOnline.ps1 @@ -25,9 +25,9 @@ .PARAMETER EnrollmentRoot Where imaging staged things. Expects: \display-type.txt Dashboard | Lobby | 3DPrintRoom - \kiosk\Install-ShopdbKiosk.ps1 - \kiosk\shopdb-key.txt (optional) line1 collector.ingest PAT, - line2 geenforce.fetch PAT + and, beside this script (see -KioskRoot): + kiosk\Install-ShopdbKiosk.ps1 + kiosk\shopdb-key.txt (optional) labelled: collector=..., fetch=... .PARAMETER TaskName The scheduled task to remove once installation succeeds. @@ -42,6 +42,15 @@ [CmdletBinding()] param( [string]$EnrollmentRoot = 'C:\Enrollment', + + # Where the staged installer and key live. Defaults to kiosk\ NEXT TO THIS + # SCRIPT, not under EnrollmentRoot: startnet copies the whole type-specific + # tree to + # C:\Enrollment\shopfloor-setup\gea-shopfloor-display\ + # so the payload arrives beside this file, not at C:\Enrollment\kiosk. + # Getting this wrong is silent - the bootstrap just logs "not staged" every + # cycle and never installs anything. + [string]$KioskRoot = (Join-Path $PSScriptRoot 'kiosk'), [string]$BaseUrl = 'https://tsgwp00525.wjs.geaerospace.net/shopdb', [string]$TaskName = 'ShopDB Kiosk Bootstrap', [int]$TimeoutSeconds = 30 @@ -93,7 +102,7 @@ if ($displayType -notin @('Dashboard','Lobby','3DPrintRoom')) { } Log "DisplayType: $displayType" -$installer = Join-Path $EnrollmentRoot 'kiosk\Install-ShopdbKiosk.ps1' +$installer = Join-Path $KioskRoot 'Install-ShopdbKiosk.ps1' if (-not (Test-Path $installer)) { Log "Installer not staged at $installer. Leaving armed." return @@ -118,7 +127,7 @@ try { } # --- keys ---------------------------------------------------------------- -$keyFile = Join-Path $EnrollmentRoot 'kiosk\shopdb-key.txt' +$keyFile = Join-Path $KioskRoot 'shopdb-key.txt' $collectorKey = '' $fetchToken = '' if (Test-Path $keyFile) {