2024-12-15 00:29:51 +01:00
|
|
|
{
|
|
|
|
pkgs,
|
|
|
|
lib,
|
|
|
|
config,
|
|
|
|
...
|
|
|
|
}:
|
2023-10-28 22:09:36 +02:00
|
|
|
{
|
2024-06-23 23:57:03 +02:00
|
|
|
networking = {
|
|
|
|
hostName = config.frogeye.name;
|
|
|
|
domain = "geoffrey.frogeye.fr";
|
|
|
|
};
|
2023-11-22 00:52:31 +01:00
|
|
|
|
2023-10-28 22:09:36 +02:00
|
|
|
time.timeZone = "Europe/Amsterdam";
|
|
|
|
|
2023-12-18 19:50:13 +01:00
|
|
|
boot.tmp.cleanOnBoot = true;
|
2023-11-28 00:34:30 +01:00
|
|
|
|
2023-10-28 22:09:36 +02:00
|
|
|
# TODO qwerty-fr for console
|
|
|
|
|
|
|
|
# Enable CUPS to print documents
|
|
|
|
services.printing.enable = true;
|
|
|
|
|
|
|
|
# Enable passwordless sudo
|
2023-12-05 23:11:54 +01:00
|
|
|
# TODO execWheelOnly? sudo-rs?
|
2024-12-15 00:29:51 +01:00
|
|
|
security.sudo.extraRules = [
|
|
|
|
{
|
|
|
|
groups = [ "wheel" ];
|
|
|
|
commands = [
|
|
|
|
{
|
|
|
|
command = "ALL";
|
|
|
|
options = [ "NOPASSWD" ];
|
|
|
|
}
|
|
|
|
];
|
|
|
|
}
|
|
|
|
];
|
2023-10-28 22:09:36 +02:00
|
|
|
|
2024-02-17 23:35:53 +01:00
|
|
|
# UPST disko --root-mountpoint doesn't work when using flake, workaround:
|
|
|
|
disko.rootMountPoint = "/mnt/nixos";
|
|
|
|
|
2023-10-28 22:09:36 +02:00
|
|
|
environment.systemPackages = with pkgs; [
|
|
|
|
wget
|
|
|
|
kexec-tools
|
2023-12-16 19:06:10 +01:00
|
|
|
neovim # So we have a working editor in rescue mode
|
|
|
|
git # Needed for all the fetchFromGit in this repo on nixos-rebuild
|
2023-10-28 22:09:36 +02:00
|
|
|
];
|
|
|
|
|
2024-03-10 19:13:57 +01:00
|
|
|
i18n = {
|
|
|
|
defaultLocale = "en_GB.UTF-8";
|
|
|
|
extraLocaleSettings = {
|
|
|
|
LC_TIME = "en_DK.UTF-8"; # Should give YYYY-MM-DD but doesn't work for browser & Thunderbird :(
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2024-06-01 18:22:50 +02:00
|
|
|
nix = {
|
|
|
|
package = pkgs.lix;
|
|
|
|
settings = {
|
2024-12-15 00:29:51 +01:00
|
|
|
experimental-features = [
|
|
|
|
"nix-command"
|
|
|
|
"flakes"
|
|
|
|
];
|
2024-06-01 18:22:50 +02:00
|
|
|
warn-dirty = false;
|
|
|
|
};
|
2024-01-07 12:54:43 +01:00
|
|
|
};
|
2023-11-23 13:21:29 +01:00
|
|
|
|
2023-10-28 22:09:36 +02:00
|
|
|
programs = {
|
2023-12-09 00:08:01 +01:00
|
|
|
adb.enable = true;
|
2023-10-28 22:09:36 +02:00
|
|
|
# Enable compilation cache
|
|
|
|
ccache.enable = true;
|
|
|
|
# TODO Not enough, see https://nixos.wiki/wiki/CCache.
|
|
|
|
# Might want to see if it's worth using on NixOS
|
2023-12-16 18:58:13 +01:00
|
|
|
less.lessopen = null; # Don't use lessopen
|
2023-10-28 22:09:36 +02:00
|
|
|
|
|
|
|
# Let users mount disks
|
|
|
|
udevil.enable = true;
|
|
|
|
};
|
|
|
|
|
|
|
|
services = {
|
|
|
|
# Enable the OpenSSH daemon
|
|
|
|
openssh.enable = true;
|
|
|
|
|
|
|
|
# Time sychronisation
|
|
|
|
chrony = {
|
|
|
|
enable = true;
|
|
|
|
servers = map (n: "${toString n}.europe.pool.ntp.org") (lib.lists.range 0 3);
|
|
|
|
};
|
|
|
|
|
|
|
|
# Prevent power button from shutting down the computer.
|
|
|
|
# On Pinebook it's too easy to hit,
|
|
|
|
# on others I sometimes turn it off when unsuspending.
|
|
|
|
logind.extraConfig = "HandlePowerKey=ignore";
|
|
|
|
|
2024-09-15 22:19:20 +02:00
|
|
|
udev.extraRules = ''
|
|
|
|
# DYMO LabelPOINT 350
|
|
|
|
ACTION=="add", SUBSYSTEMS=="usb", ATTRS{idVendor}=="0922", ATTRS{idProduct}=="0015", MODE="0666"
|
|
|
|
'';
|
|
|
|
|
2023-10-28 22:09:36 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
# TODO Hibernation?
|
|
|
|
|
|
|
|
# Use defaults from
|
2024-06-03 19:20:17 +02:00
|
|
|
system.stateVersion = "24.05";
|
2023-10-28 22:09:36 +02:00
|
|
|
|
|
|
|
}
|