about summary refs log tree commit diff
path: root/release.nix
diff options
context:
space:
mode:
authoraszlig <aszlig@redmoonstudios.org>2015-06-27 17:43:53 +0200
committeraszlig <aszlig@redmoonstudios.org>2015-06-27 17:45:56 +0200
commit92e495b6b19afe7b0a5627c0bf6c3cc55b9034dd (patch)
tree507d16433bee20e518fd2e72b7d2faae8b8322e0 /release.nix
parent27dce7bc3400bbe4d97ee8bd3f841df2cb179f60 (diff)
release.nix: Build ISO images for all machines.
Originally only needed for "kzerza", because that machine has always
resided on an USB stick, but could be useful for "arilou" and others as
well. That way you always have a (hopefully working) USB and CD image
available for all machines.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Diffstat (limited to 'release.nix')
-rw-r--r--release.nix15
1 files changed, 15 insertions, 0 deletions
diff --git a/release.nix b/release.nix
index 723bbc8c..32f73a24 100644
--- a/release.nix
+++ b/release.nix
@@ -56,6 +56,21 @@ in with pkgsUpstream.lib; with builtins; {
     attrs.build.config.system.build.toplevel
   ) (import "${vuizvui}/machines" { inherit system; });
 
+  isoImages = let
+    machineBase = import "${vuizvui}/machines" { inherit system; };
+    buildIso = attrs: let
+      name = attrs.iso.config.networking.hostName;
+    in pkgsUpstream.runCommand "vuizvui-iso-${name}" {
+      meta.description = "Live CD/USB stick of ${name}";
+      iso = attrs.iso.config.system.build.isoImage;
+      passthru.config = attrs.iso.config;
+    } ''
+      mkdir -p "$out/nix-support"
+      echo "file iso" $iso/iso/*.iso* \
+        >> "$out/nix-support/hydra-build-products"
+    '';
+  in mapAttrsRecursiveCond (m: !(m ? iso)) (const buildIso) machineBase;
+
   tests = mapAttrsRecursiveCond (t: !(t ? test)) (const id)
     (import "${vuizvui}/tests" { inherit system; });