1
Fork 0
satellite/hosts/nixos/iso/default.nix

75 lines
1.8 KiB
Nix
Raw Normal View History

2024-08-27 16:28:49 +02:00
# See the wiki for more details https://wiki.nixos.org/wiki/Creating_a_NixOS_live_CD
#
# Can be built with
# nix build .#nixosConfigurations.iso.config.system.build.isoImage
2024-08-27 21:32:51 +02:00
{
modulesPath,
inputs,
2024-08-27 21:56:19 +02:00
outputs,
2024-08-27 21:32:51 +02:00
pkgs,
...
}:
2024-08-26 17:38:47 +02:00
{
2024-08-27 16:28:49 +02:00
# {{{ Imports
2024-08-27 21:56:19 +02:00
imports = builtins.attrValues outputs.nixosModules ++ [
2024-08-26 17:38:47 +02:00
"${modulesPath}/installer/cd-dvd/installation-cd-minimal.nix"
2024-08-27 21:32:51 +02:00
inputs.sops-nix.nixosModules.sops
2024-08-27 21:56:19 +02:00
../common/global/cli/fish.nix
../common/optional/services/wpa_supplicant.nix
2024-08-27 16:28:49 +02:00
../common/optional/services/kanata.nix
2024-08-26 17:38:47 +02:00
];
2024-08-27 16:28:49 +02:00
# }}}
2024-08-27 13:30:17 +02:00
# {{{ Automount hermes
fileSystems."/hermes" = {
2024-08-27 22:11:56 +02:00
device = "/dev/disk/by-uuid/41311200-3403-4324-9ad3-4fc45a061152";
2024-08-27 13:30:17 +02:00
neededForBoot = true;
options = [
"nofail"
"x-systemd.automount"
];
};
# }}}
2024-08-27 21:32:51 +02:00
# {{{ Nix config
nix = {
# Flake support and whatnot
package = pkgs.lix;
# Enable flakes and new 'nix' command
settings.experimental-features = [
"nix-command"
"flakes"
];
};
# }}}
# {{{ SSH keys
users.users.pilot.openssh.authorizedKeys.keyFiles = [
../calypso/keys/id_ed25519.pub
../lapetus/keys/id_ed25519.pub
../tethys/keys/id_ed25519.pub
];
# }}}
# {{{ Install some packages
2024-08-27 22:11:56 +02:00
environment.systemPackages =
let
cloneConfig = pkgs.writeShellScriptBin "liftoff" ''
git clone git@github.com:prescientmoon/everything-nix.git
cd everything-nix
'';
in
with pkgs;
[
sops # Secret editing
neovim # Text editor
cloneConfig # Clones my nixos config from github
];
# }}}
# Tell sops-nix to use the hermes keys for decrypting secrets
sops.age.sshKeyPaths = [ "/hermes/secrets/hermes/ssh_host_ed25519_key" ];
2024-08-27 16:28:49 +02:00
# Fast but bad compression
# isoImage.squashfsCompression = "gzip -Xcompression-level 1";
2024-08-26 17:38:47 +02:00
}