From 1770396bf5eefcff2a613201a5a4d3b36b0ee9b6 Mon Sep 17 00:00:00 2001 From: Griffin Smith Date: Tue, 29 Sep 2020 17:54:36 -0400 Subject: feat(gs/system): Add ISO config Add configuration for a live install iso based on the depot's nixpkgs pin and with a couple of networking-based options tweaked a bit. Change-Id: I208bd0f7815fe54fc805e8995a8288d7a0d36f84 Reviewed-on: https://cl.tvl.fyi/c/depot/+/2014 Reviewed-by: glittershark Tested-by: BuildkiteCI --- users/glittershark/system/system/default.nix | 9 +++++++-- users/glittershark/system/system/iso.nix | 17 +++++++++++++++++ 2 files changed, 24 insertions(+), 2 deletions(-) create mode 100644 users/glittershark/system/system/iso.nix diff --git a/users/glittershark/system/system/default.nix b/users/glittershark/system/system/default.nix index dd84dc71db..12cde445fe 100644 --- a/users/glittershark/system/system/default.nix +++ b/users/glittershark/system/system/default.nix @@ -1,4 +1,4 @@ -{ depot, pkgs, ... }: +args @ { depot, pkgs, ... }: rec { chupacabra = import ./machines/chupacabra.nix; @@ -7,8 +7,13 @@ rec { configuration = chupacabra; }).system; + iso = import ./iso.nix args; + # Build chupacabra in CI - meta.targets = [ "chupacabraSystem" ]; + meta.targets = [ + "chupacabraSystem" + "iso" + ]; rebuilder = let diff --git a/users/glittershark/system/system/iso.nix b/users/glittershark/system/system/iso.nix new file mode 100644 index 0000000000..056922ee1e --- /dev/null +++ b/users/glittershark/system/system/iso.nix @@ -0,0 +1,17 @@ +{ pkgs, ... }: + +let + configuration = { ... }: { + imports = [ + "${pkgs.nixpkgsSrc}/nixos/modules/installer/cd-dvd/installation-cd-minimal-new-kernel.nix" + "${pkgs.nixpkgsSrc}/nixos/modules/installer/cd-dvd/channel.nix" + ]; + + networking.networkmanager.enable = true; + networking.useDHCP = false; + networking.firewall.enable = false; + networking.wireless.enable = pkgs.lib.mkForce false; + }; +in (pkgs.nixos { + inherit configuration; +}).config.system.build.isoImage -- cgit 1.4.1