From 618721937826328bc10f9e2f6a3cd6e337cc0638 Mon Sep 17 00:00:00 2001 From: cproudlock Date: Tue, 13 Oct 2026 17:12:51 -0400 Subject: [PATCH] BPRT sync: point the page and docstrings at static/Sync-BPRT.ps1 Follow-up to 92f1e62, which moved the file but missed these references. --- webapp/services/bprt_sync.py | 7 +++---- webapp/templates/updates_bprt.html | 4 ++-- webapp/views/bprt_sync.py | 2 +- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/webapp/services/bprt_sync.py b/webapp/services/bprt_sync.py index 9f2036e..c4bc1b3 100644 --- a/webapp/services/bprt_sync.py +++ b/webapp/services/bprt_sync.py @@ -6,7 +6,7 @@ packages, the Office zips and the bulk-enroll orchestrator scripts. The vendor keeps it current on the user's GE work PC with MediaCreator Lite; this server is only reachable from there over the GE network (this webapp and SSH, no SMB), and never reaches out itself. So the user runs -scripts/windows/Sync-BPRT.ps1 there, which: +webapp/static/Sync-BPRT.ps1 there (downloadable from the BPRT page), which: 1. GETs manifest.json (path, size, sha256 of every vendor file here); 2. hashes its own copy and uploads only new or changed files, plus a @@ -1434,11 +1434,10 @@ def active_imaging(): def sync_script(): - """Path of scripts/windows/Sync-BPRT.ps1 when the webapp can serve it.""" + """Path of static/Sync-BPRT.ps1 (shipped with the webapp) when it can be served.""" here = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) for p in (os.environ.get("BPRT_SYNC_SCRIPT", ""), - os.path.join(here, "static", "Sync-BPRT.ps1"), - os.path.join(here, "..", "scripts", "windows", "Sync-BPRT.ps1")): + os.path.join(here, "static", "Sync-BPRT.ps1")): if p and os.path.isfile(p): return os.path.abspath(p) return None diff --git a/webapp/templates/updates_bprt.html b/webapp/templates/updates_bprt.html index dca464f..3b994c3 100644 --- a/webapp/templates/updates_bprt.html +++ b/webapp/templates/updates_bprt.html @@ -361,8 +361,8 @@
  1. Let MediaCreator Lite finish updating its cache on the GE work PC.
  2. Get Sync-BPRT.ps1 - {% if script_available %}(download it from here, or from the pxe repo, scripts/windows/) - {% else %}from the pxe repo, scripts/windows/Sync-BPRT.ps1{% endif %}, + {% if script_available %}(download it from here) + {% else %}from the pxe repo, webapp/static/Sync-BPRT.ps1{% endif %}, and run it in Windows PowerShell. Look first with -DryRun (nothing is uploaded):
    powershell -ExecutionPolicy Bypass -File .\Sync-BPRT.ps1 -DryRun
     powershell -ExecutionPolicy Bypass -File .\Sync-BPRT.ps1
    diff --git a/webapp/views/bprt_sync.py b/webapp/views/bprt_sync.py index 641786c..c2c7a6c 100644 --- a/webapp/views/bprt_sync.py +++ b/webapp/views/bprt_sync.py @@ -1,6 +1,6 @@ """Updates > BPRT: bring the vendor bulk-enroll folder over from the work PC. -The work PC runs scripts/windows/Sync-BPRT.ps1, which reads manifest.json +The work PC runs Sync-BPRT.ps1 (webapp/static, downloadable here), which reads manifest.json here, uploads the new and changed files over SSH into BPRT-incoming// and points the user at this page. Here a batch is validated, its diff shown, and activated (a new BPRT built from hard links and swapped in by rename);