disko/tests/disko-install/configuration.nix
Jörg Thalheim bde7dd352c add disko-install command
disko-install combines disko and nixos-install into a single command.

Example usage:

  sudo ./disko-install --flake /someflake#eva --disk sda /dev/zvol/zroot/test
2024-03-01 09:48:08 +00:00

24 lines
806 B
Nix

{ lib, pkgs, modulesPath, ... }: {
imports = [
(modulesPath + "/testing/test-instrumentation.nix")
(modulesPath + "/profiles/qemu-guest.nix")
(modulesPath + "/profiles/minimal.nix")
];
networking.hostName = "disko-machine";
# do not try to fetch stuff from the internet
nix.settings = {
substituters = lib.mkForce [ ];
hashed-mirrors = null;
connect-timeout = 3;
flake-registry = pkgs.writeText "flake-registry" ''{"flakes":[],"version":2}'';
experimental-features = [ "nix-command" "flakes" ];
};
services.openssh.enable = true;
boot.kernelParams = [ "console=tty0" ] ++
(lib.optional (pkgs.stdenv.hostPlatform.isAarch) "ttyAMA0,115200") ++
(lib.optional (pkgs.stdenv.hostPlatform.isRiscV64) "ttySIF0,115200") ++
[ "console=ttyS0,115200" ];
}