feat(gameboot-windows): add FirstBoot-FwsGameboot orchestrator script
Add PowerShell script to orchestrate first-boot initialization on Windows gaming system. The script executes on first boot only: 1. Install-FwsGameboot.ps1 for gaming account setup and auto-login 2. Install-Games.ps1 to download and install configured games from official sources A marker file prevents re-execution on subsequent boots. Idempotent and safe to re-run.
This commit is contained in:
+34
@@ -0,0 +1,34 @@
|
|||||||
|
<#
|
||||||
|
FirstBoot-FwsGameboot.ps1 — orchestrateur de PREMIER DEMARRAGE (une seule fois).
|
||||||
|
|
||||||
|
Au tout premier boot du Windows gaming, execute automatiquement :
|
||||||
|
1. Install-FwsGameboot.ps1 (composant de retour + auto-login + taches) ;
|
||||||
|
2. Install-Games.ps1 (telecharge+lance les installeurs officiels des
|
||||||
|
jeux marques autoinstall dans installers.json).
|
||||||
|
Puis pose un marqueur pour ne PLUS rien refaire aux boots suivants.
|
||||||
|
|
||||||
|
Cablage (le declencheur du "premier boot") : soit via autounattend.xml
|
||||||
|
<FirstLogonCommands> quand FWS pilote l'install Windows (cf. README), soit via
|
||||||
|
une entree RunOnce. Idempotent : re-lancable sans risque (le marqueur protege).
|
||||||
|
#>
|
||||||
|
#Requires -RunAsAdministrator
|
||||||
|
$ErrorActionPreference = 'Continue'
|
||||||
|
$here = Split-Path -Parent $MyInvocation.MyCommand.Path
|
||||||
|
$done = Join-Path $Env:ProgramData 'FWS\.firstboot-done'
|
||||||
|
|
||||||
|
if (Test-Path $done) { Write-Host "FWS first boot deja effectue — rien a faire."; return }
|
||||||
|
|
||||||
|
Write-Host "== FWS premier demarrage : configuration gameboot + installation des jeux =="
|
||||||
|
|
||||||
|
# 1) Composant de retour + auto-login (compte gaming SANS mot de passe recommande).
|
||||||
|
try { & (Join-Path $here 'Install-FwsGameboot.ps1') }
|
||||||
|
catch { Write-Warning "Install-FwsGameboot a echoue : $_" }
|
||||||
|
|
||||||
|
# 2) Installation des jeux (sources officielles Riot).
|
||||||
|
try { & (Join-Path $here 'Install-Games.ps1') }
|
||||||
|
catch { Write-Warning "Install-Games a echoue : $_" }
|
||||||
|
|
||||||
|
# Marqueur "fait" (dans le meme dossier durci que le reste).
|
||||||
|
New-Item -ItemType Directory -Force -Path (Split-Path $done) | Out-Null
|
||||||
|
New-Item -ItemType File -Force -Path $done | Out-Null
|
||||||
|
Write-Host "== FWS premier demarrage termine =="
|
||||||
Reference in New Issue
Block a user