nixos/hosts/gendry.jakehillion-terminals.ts.hillion.co.uk/default.nix

81 lines
2.3 KiB
Nix
Raw Normal View History

2022-11-18 20:47:23 +00:00
{ config, pkgs, lib, ... }:
{
imports = [
../../modules/common/default.nix
2023-01-21 18:32:16 +00:00
../../modules/spotify/default.nix
2023-01-24 20:26:59 +00:00
./bluetooth.nix
2022-11-18 20:47:23 +00:00
./hardware-configuration.nix
./persist.nix
2022-11-18 20:47:23 +00:00
];
2023-04-08 15:29:11 +01:00
config = {
system.stateVersion = "22.05";
networking.hostName = "gendry";
networking.domain = "jakehillion-terminals.ts.hillion.co.uk";
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
2023-04-19 20:41:53 +01:00
## Desktop
custom.desktop.awesome.enable = true;
2023-04-08 15:29:11 +01:00
## Resilio
custom.resilio.enable = true;
services.resilio.deviceName = "gendry.jakehillion-terminals";
services.resilio.directoryRoot = "/data/sync";
services.resilio.storagePath = "/data/sync/.sync";
custom.resilio.folders =
let
folderNames = [
"dad"
"joseph"
"projects"
"resources"
"sync"
];
mkFolder = name: {
name = name;
secret = {
name = "resilio/plain/${name}";
file = ../../secrets/resilio/plain/${name}.age;
};
};
in
builtins.map (mkFolder) folderNames;
2022-11-18 20:47:23 +00:00
2023-04-08 15:29:11 +01:00
## Tailscale
age.secrets."tailscale/gendry.jakehillion-terminals.ts.hillion.co.uk".file = ../../secrets/tailscale/gendry.jakehillion-terminals.ts.hillion.co.uk.age;
2023-04-17 21:22:04 +01:00
custom.tailscale = {
enable = true;
preAuthKeyFile = config.age.secrets."tailscale/gendry.jakehillion-terminals.ts.hillion.co.uk".path;
};
2022-11-18 20:47:23 +00:00
2023-04-08 15:29:11 +01:00
## Password (for interactive logins)
age.secrets."passwords/gendry.jakehillion-terminals.ts.hillion.co.uk/jake".file = ../../secrets/passwords/gendry.jakehillion-terminals.ts.hillion.co.uk/jake.age;
users.users."jake".passwordFile = config.age.secrets."passwords/gendry.jakehillion-terminals.ts.hillion.co.uk/jake".path;
2022-11-18 20:47:23 +00:00
2023-04-08 15:29:11 +01:00
security.sudo.wheelNeedsPassword = lib.mkForce true;
2022-11-18 20:47:23 +00:00
2023-04-08 15:29:11 +01:00
## Enable btrfs compression
fileSystems."/data".options = [ "compress=zstd" ];
fileSystems."/nix".options = [ "compress=zstd" ];
2023-01-07 17:02:16 +00:00
2023-04-08 15:29:11 +01:00
## Graphics
boot.initrd.kernelModules = [ "amdgpu" ];
services.xserver.videoDrivers = [ "amdgpu" ];
2022-11-18 20:47:23 +00:00
2023-04-08 15:29:11 +01:00
## Spotify
home-manager.users.jake.services.spotifyd.settings = {
global = {
device_name = "Gendry";
device_type = "computer";
bitrate = 320;
};
2023-01-21 18:32:16 +00:00
};
};
}