enrollment: auto-activate uploaded ppkg via ppkg.conf (no boot.wim edit)
startnet.cmd now sources SOURCE_PPKG/PPKG_VER/PPKG_EXP from \\<pxe>\enrollment\ppkg.conf (baked-in values kept as fallback if the file is missing). The webapp writes ppkg.conf on upload for standard GCCH_..._v<ver>.ppkg files: version parsed from the filename, optional expiry field (blank keeps current), so a new ppkg goes live at next boot with no startnet/boot.wim edit. Enrollment page shows the active ppkg. ppkg.conf seeded on the share (v4.16) and the ppkg.conf-aware startnet.cmd deployed into boot.wim.
This commit is contained in:
@@ -176,10 +176,23 @@ set /p enroll=Enter your choice (1-6):
|
||||
REM --- PPKG configuration (constructed at menu time, see docs) ---
|
||||
REM Vendor ships one source PPKG; we construct the BPRT-tagged filename
|
||||
REM by filling in Office, Region, Expiry, Version on the target copy.
|
||||
REM Update SOURCE_PPKG + PPKG_VER when a new PPKG is released.
|
||||
set SOURCE_PPKG=GCCH_Prod_SFLD_v4.16.ppkg
|
||||
set PPKG_VER=v4.16
|
||||
set PPKG_EXP=20260831
|
||||
REM The ACTIVE ppkg is read from \\172.16.9.1\enrollment\ppkg.conf, which the
|
||||
REM PXE webapp writes on upload - so a new ppkg goes live with no startnet edit.
|
||||
REM The baked-in values below are only a fallback if ppkg.conf is missing.
|
||||
net use Y: \\172.16.9.1\enrollment /user:pxe-upload pxe /persistent:no >nul 2>&1
|
||||
set SOURCE_PPKG=
|
||||
set PPKG_VER=
|
||||
set PPKG_EXP=
|
||||
if exist "Y:\ppkg.conf" (
|
||||
for /f "usebackq tokens=1,* delims==" %%A in ("Y:\ppkg.conf") do (
|
||||
if /i "%%A"=="SOURCE_PPKG" set "SOURCE_PPKG=%%B"
|
||||
if /i "%%A"=="PPKG_VER" set "PPKG_VER=%%B"
|
||||
if /i "%%A"=="PPKG_EXP" set "PPKG_EXP=%%B"
|
||||
)
|
||||
)
|
||||
if "%SOURCE_PPKG%"=="" set SOURCE_PPKG=GCCH_Prod_SFLD_v4.16.ppkg
|
||||
if "%PPKG_VER%"=="" set PPKG_VER=v4.16
|
||||
if "%PPKG_EXP%"=="" set PPKG_EXP=20260831
|
||||
set REGION=US
|
||||
|
||||
set OFFICE=
|
||||
|
||||
Reference in New Issue
Block a user