mirror of
https://gitlab.com/upRootNutrition/dotfiles.git
synced 2025-08-09 05:14:41 -05:00
refactor: abstacted records
This commit is contained in:
parent
64572cb106
commit
06a684fa32
42 changed files with 211 additions and 202 deletions
|
@ -1,64 +1,16 @@
|
|||
{ moduleFunctions }:
|
||||
let
|
||||
|
||||
configPath = ./config;
|
||||
printerPath = configPath + /printers;
|
||||
|
||||
devicesFunctions = {
|
||||
ownerWriteOthersReadMask = [
|
||||
"fmask=0022"
|
||||
"dmask=0022"
|
||||
];
|
||||
ownerExclusiveReadWriteMask = [
|
||||
"fmask=0077"
|
||||
"dmask=0077"
|
||||
];
|
||||
readWritePermissions = [
|
||||
"rw"
|
||||
];
|
||||
sambaPermissions = [
|
||||
"rw"
|
||||
"gid=100"
|
||||
"vers=3.0"
|
||||
"x-systemd.automount"
|
||||
"x-systemd.requires=network-online.target"
|
||||
];
|
||||
sshfsOptions = [
|
||||
"allow_other"
|
||||
"_netdev"
|
||||
"x-systemd.automount"
|
||||
"reconnect"
|
||||
"user"
|
||||
"ServerAliveInterval=15"
|
||||
"IdentityFile=/var/run/secrets/ssh/private"
|
||||
];
|
||||
fileModeAndDirMode = [
|
||||
"file_mode=0644"
|
||||
"dir_mode=0755"
|
||||
];
|
||||
userIdForUser0 = [
|
||||
"uid=1000"
|
||||
];
|
||||
userIdForUser1 = [
|
||||
"uid=1002"
|
||||
];
|
||||
dummy = [
|
||||
];
|
||||
ceresStorageDriveName = "NAS1";
|
||||
ceresIP = "192.168.50.140";
|
||||
deimosIP = "192.168.50.142";
|
||||
marsIP = "192.168.50.218";
|
||||
phoneIP = "192.168.50.243";
|
||||
phobosIP = "192.168.50.180";
|
||||
synologyIP = "192.168.50.210";
|
||||
brotherIP = "192.168.50.195";
|
||||
};
|
||||
|
||||
deviceswithFunctions = builtins.listToAttrs (
|
||||
map
|
||||
(name: {
|
||||
name = builtins.substring 0 (builtins.stringLength name - 4) name;
|
||||
value = import (configPath + "/${name}") {
|
||||
inherit
|
||||
devicesFunctions
|
||||
moduleFunctions
|
||||
;
|
||||
};
|
||||
})
|
||||
|
@ -75,7 +27,7 @@ let
|
|||
name = builtins.substring 0 (builtins.stringLength name - 4) name;
|
||||
value = import (printerPath + "/${name}") {
|
||||
inherit
|
||||
devicesFunctions
|
||||
moduleFunctions
|
||||
;
|
||||
};
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue