mirror of
https://codeberg.org/leana8959/.files.git
synced 2025-12-06 22:59:15 +00:00
ref(nix): formatted with nixfmt-rfc-style
This commit is contained in:
parent
36a2265325
commit
23404db605
40 changed files with 574 additions and 474 deletions
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
age = {
|
||||
identityPaths = ["/home/leana/.ssh/id_ed25519"];
|
||||
identityPaths = [ "/home/leana/.ssh/id_ed25519" ];
|
||||
secrets.sshconcfig = {
|
||||
file = ../../secrets/sshconfig.age;
|
||||
path = "/home/leana/.ssh/config";
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
sound = {
|
||||
enable = true;
|
||||
mediaKeys.enable = true;
|
||||
|
|
@ -12,5 +13,9 @@
|
|||
jack.enable = true;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [helvum pavucontrol easyeffects];
|
||||
environment.systemPackages = with pkgs; [
|
||||
helvum
|
||||
pavucontrol
|
||||
easyeffects
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
systemd.services.battery-charge-threshold = {
|
||||
enable = true;
|
||||
description = "Set the battery charge threshold";
|
||||
|
|
@ -13,6 +14,6 @@
|
|||
Restart = "on-failure";
|
||||
ExecStart = "${pkgs.bash}/bin/bash -c 'echo 70 > /sys/class/power_supply/BAT1/charge_control_start_threshold; echo 80 > /sys/class/power_supply/BAT1/charge_control_end_threshold'";
|
||||
};
|
||||
wantedBy = ["multi-user.target"];
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
system.stateVersion = "23.11";
|
||||
|
||||
imports = [
|
||||
|
|
@ -32,11 +33,14 @@
|
|||
"docker"
|
||||
"vboxusers"
|
||||
];
|
||||
packages = [];
|
||||
packages = [ ];
|
||||
};
|
||||
|
||||
nix = {
|
||||
package = pkgs.nixFlakes;
|
||||
settings.trusted-users = ["root" "@wheel"];
|
||||
settings.trusted-users = [
|
||||
"root"
|
||||
"@wheel"
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
services = {
|
||||
xserver.enable = true;
|
||||
|
||||
|
|
@ -20,7 +21,7 @@
|
|||
xserver.windowManager.xmonad = {
|
||||
enable = true;
|
||||
enableContribAndExtras = true;
|
||||
extraPackages = hp: with hp; [neat-interpolation];
|
||||
extraPackages = hp: with hp; [ neat-interpolation ];
|
||||
};
|
||||
|
||||
xserver.libinput = {
|
||||
|
|
|
|||
|
|
@ -7,15 +7,19 @@
|
|||
pkgs,
|
||||
modulesPath,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
}:
|
||||
{
|
||||
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
||||
|
||||
boot.initrd.availableKernelModules = ["xhci_pci" "ahci" "usb_storage" "sd_mod"];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = ["kvm-intel"];
|
||||
boot.extraModulePackages = [];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/7810e3a3-fed9-4c2d-8a39-a6063d0863cf";
|
||||
|
|
@ -29,9 +33,7 @@
|
|||
fsType = "vfat";
|
||||
};
|
||||
|
||||
swapDevices = [
|
||||
{device = "/dev/disk/by-uuid/2fd42520-5c2c-4d64-82ba-613033d34799";}
|
||||
];
|
||||
swapDevices = [ { device = "/dev/disk/by-uuid/2fd42520-5c2c-4d64-82ba-613033d34799"; } ];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
{pkgs, ...}: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
time.timeZone = "Europe/Paris";
|
||||
i18n = {
|
||||
defaultLocale = "en_US.UTF-8";
|
||||
|
|
@ -72,15 +73,29 @@
|
|||
EnumerateSkipFirst = null;
|
||||
};
|
||||
|
||||
"Hotkey/TriggerKeys" = {};
|
||||
"Hotkey/AltTriggerKeys" = {"0" = "Shift_L";};
|
||||
"Hotkey/EnumerateGroupForwardKeys" = {"0" = "Control+space";};
|
||||
"Hotkey/EnumerateGroupBackwardKeys" = {"0" = "Control+Shift+space";};
|
||||
"Hotkey/TriggerKeys" = { };
|
||||
"Hotkey/AltTriggerKeys" = {
|
||||
"0" = "Shift_L";
|
||||
};
|
||||
"Hotkey/EnumerateGroupForwardKeys" = {
|
||||
"0" = "Control+space";
|
||||
};
|
||||
"Hotkey/EnumerateGroupBackwardKeys" = {
|
||||
"0" = "Control+Shift+space";
|
||||
};
|
||||
|
||||
"Hotkey/PrevPage" = {"0" = "Up";};
|
||||
"Hotkey/NextPage" = {"0" = "Down";};
|
||||
"Hotkey/PrevCandidate" = {"0" = "Shift+Tab";};
|
||||
"Hotkey/NextCandidate" = {"0" = "Tab";};
|
||||
"Hotkey/PrevPage" = {
|
||||
"0" = "Up";
|
||||
};
|
||||
"Hotkey/NextPage" = {
|
||||
"0" = "Down";
|
||||
};
|
||||
"Hotkey/PrevCandidate" = {
|
||||
"0" = "Shift+Tab";
|
||||
};
|
||||
"Hotkey/NextCandidate" = {
|
||||
"0" = "Tab";
|
||||
};
|
||||
|
||||
Behavior = {
|
||||
ActiveByDefault = false;
|
||||
|
|
|
|||
|
|
@ -4,38 +4,41 @@
|
|||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
networking.hostName = hostname;
|
||||
|
||||
networking.networkmanager.enable = lib.mkForce false;
|
||||
|
||||
services.openssh.enable = true;
|
||||
|
||||
fileSystems = let
|
||||
opts = [
|
||||
"noauto"
|
||||
"x-systemd.automount"
|
||||
"x-systemd.idle-timeout=60"
|
||||
"x-systemd.device-timeout=5s"
|
||||
"x-systemd.mount-timeout=5s"
|
||||
];
|
||||
in {
|
||||
"/mnt/data" = {
|
||||
device = "10.0.0.20:/mnt/mainPool/data";
|
||||
fsType = "nfs";
|
||||
options = opts;
|
||||
fileSystems =
|
||||
let
|
||||
opts = [
|
||||
"noauto"
|
||||
"x-systemd.automount"
|
||||
"x-systemd.idle-timeout=60"
|
||||
"x-systemd.device-timeout=5s"
|
||||
"x-systemd.mount-timeout=5s"
|
||||
];
|
||||
in
|
||||
{
|
||||
"/mnt/data" = {
|
||||
device = "10.0.0.20:/mnt/mainPool/data";
|
||||
fsType = "nfs";
|
||||
options = opts;
|
||||
};
|
||||
"/mnt/archive" = {
|
||||
device = "10.0.0.20:/mnt/mainPool/data/Archive";
|
||||
fsType = "nfs";
|
||||
options = opts;
|
||||
};
|
||||
"/mnt/documents" = {
|
||||
device = "10.0.0.20:/mnt/mainPool/data/Documents";
|
||||
fsType = "nfs";
|
||||
options = opts;
|
||||
};
|
||||
};
|
||||
"/mnt/archive" = {
|
||||
device = "10.0.0.20:/mnt/mainPool/data/Archive";
|
||||
fsType = "nfs";
|
||||
options = opts;
|
||||
};
|
||||
"/mnt/documents" = {
|
||||
device = "10.0.0.20:/mnt/mainPool/data/Documents";
|
||||
fsType = "nfs";
|
||||
options = opts;
|
||||
};
|
||||
};
|
||||
|
||||
networking.wireless = {
|
||||
enable = true;
|
||||
|
|
@ -46,7 +49,7 @@
|
|||
"HiddenParadize@Earth2077".psk = "@HOME@";
|
||||
"iPhone de Léana 江".psk = "@PHONE@";
|
||||
eduroam = {
|
||||
authProtocols = ["WPA-EAP"];
|
||||
authProtocols = [ "WPA-EAP" ];
|
||||
auth = ''
|
||||
pairwise=CCMP
|
||||
group=CCMP TKIP
|
||||
|
|
@ -62,11 +65,11 @@
|
|||
};
|
||||
};
|
||||
|
||||
systemd.targets.wireguard-wg0.wantedBy = lib.mkForce [];
|
||||
systemd.targets.wireguard-wg0.wantedBy = lib.mkForce [ ];
|
||||
networking.wireguard = {
|
||||
interfaces = {
|
||||
wg0 = {
|
||||
ips = ["10.66.66.50/32"];
|
||||
ips = [ "10.66.66.50/32" ];
|
||||
privateKeyFile = config.age.secrets.wireguard_priv.path;
|
||||
postSetup = ''
|
||||
${pkgs.iproute}/bin/ip route replace 10.66.66.1 dev wg0
|
||||
|
|
@ -77,7 +80,11 @@
|
|||
{
|
||||
publicKey = "amb6icauPN4P/suyNZoPsVVkB5+MiAnhFF6hIeUiNFE=";
|
||||
presharedKeyFile = config.age.secrets.wireguard_psk.path;
|
||||
allowedIPs = ["10.66.66.1/32" "10.0.0.20/32" "10.0.0.31/32"];
|
||||
allowedIPs = [
|
||||
"10.66.66.1/32"
|
||||
"10.0.0.20/32"
|
||||
"10.0.0.31/32"
|
||||
];
|
||||
endpoint = "moon.earth2077.fr:660";
|
||||
persistentKeepalive = 25;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,8 +1,5 @@
|
|||
{ pkgs, agenix, ... }:
|
||||
{
|
||||
pkgs,
|
||||
agenix,
|
||||
...
|
||||
}: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
curl
|
||||
stow
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue