nixos-config/nixos/machines/dummy/configuration.nix

62 lines
1.3 KiB
Nix
Raw Normal View History

2020-05-20 00:30:53 +02:00
{ lib, config, pkgs, ... }: {
imports = [
<modules>
<system/server/initssh.nix>
<system/all/sshd.nix>
./hardware-configuration.nix
];
# enable initrd ssh
configuration.init-ssh = {
enable = "enabled";
kernelModules = [ "virtio_pci" ];
hostECDSAKey = <secrets/init-ssh/host_ecdsa_key>;
};
networking.hostName = "dummy";
# font
# ----
programs.custom.urxvt.fontSize = 17;
programs.custom.xterm.fontSize = 17;
system.custom.fonts.dpi = 140;
# allow un-free
# -------------
nixpkgs.config.allowUnfree = true;
environment.variables.NIXPKGS_ALLOW_UNFREE = "1";
# some system stuff
# -----------------
time.timeZone = lib.mkDefault "Europe/Berlin";
#time.timeZone = lib.mkDefault "Pacific/Auckland";
#time.timeZone = lib.mkDefault "Asia/Singapore";
#time.timeZone = lib.mkDefault "Asia/Makassar";
i18n.defaultLocale = "en_US.UTF-8";
console.font = "Lat2-Terminus16";
console.keyMap = "us";
# swappiness
# ----------
# 0 = only when running out of RAM
# 100 = always swapp
boot.kernel.sysctl."vm.swappiness" = 0;
# rewire NIX_PATH
# ---------------
environment.variables.NIX_PATH = lib.mkForce "/var/src";
environment.systemPackages = [ pkgs.git ];
boot.initrd.network.postCommands = lib.mkAfter ''
echo "sleep engineering"
sleep 120
'';
}