Make the baked app a real store-path dependency via builtins.storePath
The previous commit wrapped the manifest's storePath string in a symlinkJoin. symlinkJoin passes its paths as a file, so a bare store-path string registered no dependency: Nix never substituted the closure and the symlinkJoin failed with 'radiantwave-9b57e48: No such file or directory'. builtins.storePath turns the published path into a real store-path dependency that Nix substitutes from the channel's Attic cache, so the app is baked and never compiled. Keep the raw string (publishedPath) for the updater's plain-string baseline pointer.
This commit is contained in:
@@ -93,11 +93,17 @@
|
||||
url = "${channelManifestDir}/${manifestFile}";
|
||||
}));
|
||||
|
||||
# The published closure as a plain store-path string. configuration.nix
|
||||
# wraps it in a symlinkJoin so it can live in environment.systemPackages
|
||||
# (a bare string there would be coerced with builtins.storePath, which
|
||||
# requires the closure to already be local at eval time).
|
||||
publishedApp = manifestFile: (manifestFor manifestFile).storePath;
|
||||
# The published closure as a plain store-path string. Used for the
|
||||
# updater's runtime baseline pointer (a plain string; the closure itself
|
||||
# is pulled in via publishedApp below).
|
||||
publishedPath = manifestFile: (manifestFor manifestFile).storePath;
|
||||
|
||||
# The published closure as a real store-path dependency.
|
||||
# builtins.storePath makes the derivation depend on this exact path and
|
||||
# substitute it from the channel's Attic cache (configured as a trusted
|
||||
# substituter), so the app is never compiled from source. The closure
|
||||
# itself is not fetched by this repository; RadiantWave CI publishes it.
|
||||
publishedApp = manifestFile: builtins.storePath (publishedPath manifestFile);
|
||||
|
||||
# Live app-update side channel. The manifest is served by the
|
||||
# fileserver; closures are fetched (never built) from the channel's
|
||||
@@ -249,7 +255,7 @@
|
||||
diskModule = ./disk-config.nix;
|
||||
upgradeFlakeRef = "git+https://gitea.radiantwavetech.com/RadiantWaveTech/KioskConfig.git${channel.gitRef}#radiantwavekiosk";
|
||||
extraModules = [
|
||||
(radiantwaveUpdaterModule { repo = channel.atticRepo; baseline = publishedApp "manifest.json"; })
|
||||
(radiantwaveUpdaterModule { repo = channel.atticRepo; baseline = publishedPath "manifest.json"; })
|
||||
];
|
||||
};
|
||||
radiantwavekiosk-commercial = mkKioskSystem {
|
||||
@@ -258,7 +264,7 @@
|
||||
diskModule = ./commercial-disk-config.nix;
|
||||
upgradeFlakeRef = "git+https://gitea.radiantwavetech.com/RadiantWaveTech/KioskConfig.git${channel.gitRef}#radiantwavekiosk-commercial";
|
||||
extraModules = [
|
||||
(radiantwaveUpdaterModule { repo = channel.atticRepo; baseline = publishedApp "manifest.json"; })
|
||||
(radiantwaveUpdaterModule { repo = channel.atticRepo; baseline = publishedPath "manifest.json"; })
|
||||
];
|
||||
};
|
||||
# Rotated screen for android-style displays.
|
||||
@@ -269,7 +275,7 @@
|
||||
upgradeFlakeRef = "git+https://gitea.radiantwavetech.com/RadiantWaveTech/KioskConfig.git${channel.gitRef}#radiantwavekiosk-android";
|
||||
extraModules = [
|
||||
./rotated_display.nix
|
||||
(radiantwaveUpdaterModule { repo = channel.atticRepo; baseline = publishedApp "manifest.json"; })
|
||||
(radiantwaveUpdaterModule { repo = channel.atticRepo; baseline = publishedPath "manifest.json"; })
|
||||
];
|
||||
};
|
||||
# Raspberry Pi 5.
|
||||
@@ -279,7 +285,7 @@
|
||||
extraModules = [
|
||||
(radiantwaveUpdaterModule {
|
||||
repo = channel.atticRepo;
|
||||
baseline = publishedApp "aarch64-manifest.json";
|
||||
baseline = publishedPath "aarch64-manifest.json";
|
||||
manifestFile = "aarch64-manifest.json";
|
||||
})
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user