feat: WinPE pre-config collector + simplified first-boot toolbox (SP1) #21

Merged
SilverLABS merged 14 commits from docs/winpe-preconfig-collector into main 2026-06-10 08:40:58 +00:00
3 changed files with 4 additions and 5 deletions
Showing only changes of commit 2730b29cb6 - Show all commits

View File

@@ -39,7 +39,6 @@ public static class MauiProgram
var appsDir = Path.Combine(AppContext.BaseDirectory, "apps");
builder.Services.AddSingleton<IAppInstaller>(sp => new AppInstaller(sp.GetRequiredService<IProcessRunner>(), appsDir));
builder.Services.AddSingleton<IApplyService>(sp => new ApplyService(
sp.GetRequiredService<IProcessRunner>(),
sp.GetRequiredService<IBitLockerService>(),
sp.GetRequiredService<IAppInstaller>()));
builder.Services.AddScoped<WizardState>();

View File

@@ -4,7 +4,7 @@ namespace SilverOS.Welcome.Core.Apply;
// Toolbox Apply pipeline: apps -> bitlocker -> done.
// Account creation moved to Windows Setup (WinPE collector); OS hardening runs from
// SetupComplete; sm-bootstrap teardown is owned by Setup, not the toolbox.
public sealed class ApplyService(IProcessRunner runner, IBitLockerService bitlocker, IAppInstaller installer) : IApplyService
public sealed class ApplyService(IBitLockerService bitlocker, IAppInstaller installer) : IApplyService
{
public async Task RunAsync(ApplyRequest req, IProgress<ApplyProgress> progress, CancellationToken ct = default)
{

View File

@@ -33,7 +33,7 @@ public class ApplyServiceTests
It.IsAny<IProgress<ApplyProgress>>(), It.IsAny<CancellationToken>()))
.Callback(() => order.Add("apps")).ReturnsAsync(Array.Empty<AppInstallResult>());
var sut = new ApplyService(run.Object, bl.Object, installer.Object);
var sut = new ApplyService(bl.Object, installer.Object);
var req = new ApplyRequest(Flavour(), "123456", System.Array.Empty<AppCatalogEntry>());
var progress = new List<string>();
@@ -59,7 +59,7 @@ public class ApplyServiceTests
It.IsAny<IProgress<ApplyProgress>>(), It.IsAny<CancellationToken>()))
.Callback(() => order.Add("apps")).ReturnsAsync(Array.Empty<AppInstallResult>());
var sut = new ApplyService(run.Object, bl.Object, installer.Object);
var sut = new ApplyService(bl.Object, installer.Object);
var req = new ApplyRequest(Flavour(), "", System.Array.Empty<AppCatalogEntry>());
await sut.RunAsync(req, new Progress<ApplyProgress>(_ => { }));
@@ -78,7 +78,7 @@ public class ApplyServiceTests
var installer = NoApps();
var apps = new[] { new AppCatalogEntry { Id = "firefox", Name = "Firefox" } };
var sut = new ApplyService(run.Object, bl.Object, installer.Object);
var sut = new ApplyService(bl.Object, installer.Object);
var req = new ApplyRequest(Flavour(), "123456", apps);
await sut.RunAsync(req, new Progress<ApplyProgress>(_ => { }));