Reorganize for zfs
This commit is contained in:
parent
2933964680
commit
cfb48de40c
57 changed files with 817 additions and 492 deletions
6
configurations/adb.nix
Normal file
6
configurations/adb.nix
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
programs.adb.enable = true;
|
||||||
|
users.users.charlotte.extraGroups = [ "adbusers" ];
|
||||||
|
}
|
|
@ -1,6 +1,11 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
|
custom.zfs.homeLinks = [
|
||||||
|
{ path = ".local/share/direnv"; type = "cache"; }
|
||||||
|
{ path = ".cache/lorri"; type = "cache"; }
|
||||||
|
];
|
||||||
|
|
||||||
home-manager.users.charlotte = { ... }: {
|
home-manager.users.charlotte = { ... }: {
|
||||||
programs.direnv = {
|
programs.direnv = {
|
||||||
enable = true;
|
enable = true;
|
13
configurations/docker.nix
Normal file
13
configurations/docker.nix
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
custom.zfs.systemLinks = [
|
||||||
|
{ path = "/var/lib/docker"; type = "cache"; }
|
||||||
|
{ path = "/var/lib/docker/volumes"; type = "data"; }
|
||||||
|
];
|
||||||
|
virtualisation.docker.enable = true;
|
||||||
|
users.users.charlotte.extraGroups = [
|
||||||
|
"docker"
|
||||||
|
];
|
||||||
|
|
||||||
|
}
|
|
@ -1,6 +1,10 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
|
custom.zfs.homeLinks = [
|
||||||
|
{ path = ".dropbox"; type = "data"; }
|
||||||
|
{ path = "Dropbox"; type = "data"; }
|
||||||
|
];
|
||||||
home-manager.users.charlotte = { pkgs, ... }: {
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
systemd.user.services = {
|
systemd.user.services = {
|
||||||
dropbox = {
|
dropbox = {
|
10
configurations/eid.nix
Normal file
10
configurations/eid.nix
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
services.pcscd = {
|
||||||
|
enable = true;
|
||||||
|
plugins = [ pkgs.ccid ];
|
||||||
|
};
|
||||||
|
|
||||||
|
environment.systemPackages = with pkgs; [ eid-mw ];
|
||||||
|
}
|
10
configurations/firefox.nix
Normal file
10
configurations/firefox.nix
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
{ ... }: {
|
||||||
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
|
home.packages = with pkgs; [ firefox ];
|
||||||
|
};
|
||||||
|
|
||||||
|
custom.zfs.homeLinks = [
|
||||||
|
{ path = ".cache/mozilla"; type = "cache"; }
|
||||||
|
{ path = ".mozilla"; type = "data"; }
|
||||||
|
];
|
||||||
|
}
|
25
configurations/fonts.nix
Normal file
25
configurations/fonts.nix
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
fonts = {
|
||||||
|
enableFontDir = true;
|
||||||
|
fontconfig = {
|
||||||
|
enable = true;
|
||||||
|
defaultFonts = {
|
||||||
|
emoji = [ "Noto Color Emoji" ];
|
||||||
|
monospace = [ "Fira Code" ];
|
||||||
|
sansSerif = [ "Noto Sans" ];
|
||||||
|
serif = [ "Noto Serif" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
fonts = with pkgs; [
|
||||||
|
fira-code
|
||||||
|
fira-code-symbols
|
||||||
|
font-awesome_4
|
||||||
|
noto-fonts
|
||||||
|
noto-fonts-cjk
|
||||||
|
noto-fonts-emoji
|
||||||
|
noto-fonts-extra
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
|
@ -19,7 +19,7 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
extraConfig = {
|
extraConfig = {
|
||||||
branch = {
|
branch = {
|
||||||
setupautorebase = "always";
|
autosetuprebase = "always";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
ignores = [
|
ignores = [
|
22
configurations/gnupg.nix
Normal file
22
configurations/gnupg.nix
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
custom.zfs.homeLinks = [
|
||||||
|
{ path = ".gnupg/crls.d"; type = "data"; }
|
||||||
|
{ path = ".gnupg/private-keys-v1.d"; type = "data"; }
|
||||||
|
{ path = ".gnupg/pubring.kbx"; type = "data"; }
|
||||||
|
{ path = ".gnupg/trustdb.gpg"; type = "data"; }
|
||||||
|
];
|
||||||
|
programs.gnupg.agent.enable = true;
|
||||||
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
|
programs = {
|
||||||
|
gpg.enable = true;
|
||||||
|
};
|
||||||
|
services.gpg-agent = {
|
||||||
|
enable = true;
|
||||||
|
defaultCacheTtl = 7200;
|
||||||
|
maxCacheTtl = 99999;
|
||||||
|
pinentryFlavor = "qt";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,11 +1,10 @@
|
||||||
with import <nixpkgs> { };
|
{ pkgs, ... }:
|
||||||
{ ... }:
|
|
||||||
let
|
let
|
||||||
launcher = import ../sway/launcher.nix { inherit pkgs stdenv; };
|
launcher = import ./sway/launcher.nix { inherit pkgs; stdenv = pkgs.stdenv; };
|
||||||
status-configuration = import ../sway/status-configuration.nix { inherit pkgs; };
|
status-configuration = import ./sway/status-configuration.nix { inherit pkgs; };
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
imports = [ ../base-x/default.nix ];
|
imports = [ ./base-x.nix ];
|
||||||
home-manager.users.charlotte = { pkgs, ... }: {
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
xsession = {
|
xsession = {
|
||||||
windowManager.i3 = {
|
windowManager.i3 = {
|
12
configurations/joplin.nix
Normal file
12
configurations/joplin.nix
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
|
home.packages = with pkgs; [ joplin-desktop ];
|
||||||
|
};
|
||||||
|
|
||||||
|
custom.zfs.homeLinks = [
|
||||||
|
{ path = ".config/joplin-desktop"; type = "data"; }
|
||||||
|
{ path = ".config/Joplin"; type = "data"; }
|
||||||
|
];
|
||||||
|
}
|
6
configurations/kernel.nix
Normal file
6
configurations/kernel.nix
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
# Use latest kernel
|
||||||
|
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||||
|
}
|
15
configurations/locale.nix
Normal file
15
configurations/locale.nix
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
i18n = {
|
||||||
|
defaultLocale = "en_IE.UTF-8";
|
||||||
|
extraLocaleSettings = {
|
||||||
|
LC_TIME = "en_GB.UTF-8";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
console = {
|
||||||
|
font = "Lat2-Terminus16";
|
||||||
|
keyMap = "us";
|
||||||
|
};
|
||||||
|
}
|
41
configurations/mounts.nix
Normal file
41
configurations/mounts.nix
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
imports = [ ./mounts/secret.nix ];
|
||||||
|
|
||||||
|
environment.systemPackages = [ pkgs.keyutils ];
|
||||||
|
# Remove this once https://github.com/NixOS/nixpkgs/issues/34638 is resolved
|
||||||
|
# The TL;DR is: the kernel calls out to the hard-coded path of
|
||||||
|
# /sbin/request-key as part of its CIFS auth process, which of course does
|
||||||
|
# not exist on NixOS due to the usage of Nix store paths.
|
||||||
|
system.activationScripts.symlink-requestkey = ''
|
||||||
|
if [ ! -d /sbin ]; then
|
||||||
|
mkdir /sbin
|
||||||
|
fi
|
||||||
|
ln -sfn /run/current-system/sw/bin/request-key /sbin/request-key
|
||||||
|
'';
|
||||||
|
# request-key expects a configuration file under /etc
|
||||||
|
environment.etc."request-key.conf" = {
|
||||||
|
text =
|
||||||
|
let
|
||||||
|
upcall = "${pkgs.cifs-utils}/bin/cifs.upcall";
|
||||||
|
keyctl = "${pkgs.keyutils}/bin/keyctl";
|
||||||
|
in
|
||||||
|
''
|
||||||
|
#OP TYPE DESCRIPTION CALLOUT_INFO PROGRAM
|
||||||
|
# -t is required for DFS share servers...
|
||||||
|
create cifs.spnego * * ${upcall} -t %k
|
||||||
|
create dns_resolver * * ${upcall} %k
|
||||||
|
# Everything below this point is essentially the default configuration,
|
||||||
|
# modified minimally to work under NixOS. Notably, it provides debug
|
||||||
|
# logging.
|
||||||
|
create user debug:* negate ${keyctl} negate %k 30 %S
|
||||||
|
create user debug:* rejected ${keyctl} reject %k 30 %c %S
|
||||||
|
create user debug:* expired ${keyctl} reject %k 30 %c %S
|
||||||
|
create user debug:* revoked ${keyctl} reject %k 30 %c %S
|
||||||
|
create user debug:loop:* * |${pkgs.coreutils}/bin/cat
|
||||||
|
create user debug:* * ${pkgs.keyutils}/share/keyutils/request-key-debug.sh %k %d %c %S
|
||||||
|
negate * * * ${keyctl} negate %k 30 %S
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
}
|
BIN
configurations/mounts/secret.nix
Normal file
BIN
configurations/mounts/secret.nix
Normal file
Binary file not shown.
|
@ -20,11 +20,16 @@ let
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
jdtls = import ../../packages/jdtls/default.nix { inherit pkgs; stdenv = pkgs.stdenv; };
|
jdtls = import ../packages/jdtls/default.nix { inherit pkgs; stdenv = pkgs.stdenv; };
|
||||||
kotlinls = import ../../packages/kotlin-language-server/default.nix { inherit pkgs; };
|
kotlinls = import ../packages/kotlin-language-server/default.nix { inherit pkgs; };
|
||||||
nodePackages = import ../../packages/node/default.nix { inherit pkgs; };
|
nodePackages = import ../packages/node/default.nix { inherit pkgs; };
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
|
custom.zfs.homeLinks = [
|
||||||
|
{ path = ".local/share/nvim"; type = "cache"; }
|
||||||
|
{ path = ".cache/nvim"; type = "cache"; }
|
||||||
|
];
|
||||||
|
|
||||||
home-manager.users.charlotte = { pkgs, ... }: {
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
home.packages = [
|
home.packages = [
|
||||||
(
|
(
|
||||||
|
@ -42,11 +47,11 @@ in
|
||||||
|
|
||||||
" Undo over sessions
|
" Undo over sessions
|
||||||
set undofile
|
set undofile
|
||||||
set undodir=~/.cache/nvimundo
|
set undodir=~/.cache/nvim/undo
|
||||||
|
|
||||||
" Automatically save sessions on exit and load them on start
|
" Automatically save sessions on exit and load them on start
|
||||||
function! MakeSession()
|
function! MakeSession()
|
||||||
let b:sessiondir = $HOME . "/.config/nvim/sessions" . getcwd()
|
let b:sessiondir = $HOME . "/.local/share/nvim/sessions" . getcwd()
|
||||||
if (filewritable(b:sessiondir) != 2)
|
if (filewritable(b:sessiondir) != 2)
|
||||||
exe 'silent !mkdir -p ' b:sessiondir
|
exe 'silent !mkdir -p ' b:sessiondir
|
||||||
redraw!
|
redraw!
|
||||||
|
@ -56,7 +61,7 @@ in
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! LoadSession()
|
function! LoadSession()
|
||||||
let b:sessiondir = $HOME . "/.config/nvim/sessions" . getcwd()
|
let b:sessiondir = $HOME . "/.local/share/nvim/sessions" . getcwd()
|
||||||
let b:sessionfile = b:sessiondir . "/session.vim"
|
let b:sessionfile = b:sessiondir . "/session.vim"
|
||||||
if (filereadable(b:sessionfile))
|
if (filereadable(b:sessionfile))
|
||||||
exe 'source ' b:sessionfile
|
exe 'source ' b:sessionfile
|
25
configurations/networkmanager.nix
Normal file
25
configurations/networkmanager.nix
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
custom.zfs.systemLinks = [
|
||||||
|
{ path = "/etc/NetworkManager/system-connections"; type = "data"; }
|
||||||
|
];
|
||||||
|
|
||||||
|
networking = {
|
||||||
|
hosts = { "127.0.0.1" = [ "dodona.localhost" "sandbox.localhost" ]; };
|
||||||
|
networkmanager = {
|
||||||
|
enable = true;
|
||||||
|
packages = [ pkgs.networkmanager-vpnc ];
|
||||||
|
wifi.macAddress = "random";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
users.users.charlotte.extraGroups = [
|
||||||
|
"networkmanager"
|
||||||
|
];
|
||||||
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
networkmanagerapplet
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
36
configurations/nix-index.nix
Normal file
36
configurations/nix-index.nix
Normal file
|
@ -0,0 +1,36 @@
|
||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
custom.zfs.homeLinks = [
|
||||||
|
{ path = ".cache/nix-index"; type = "cache"; }
|
||||||
|
];
|
||||||
|
|
||||||
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
nix-index
|
||||||
|
];
|
||||||
|
systemd.user = {
|
||||||
|
services.nix-index = {
|
||||||
|
Unit = {
|
||||||
|
Description = "Service to run nix-index";
|
||||||
|
};
|
||||||
|
Service = {
|
||||||
|
Type = "oneshot";
|
||||||
|
ExecStart = "${pkgs.nix-index}/bin/nix-index";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
timers.nix-index = {
|
||||||
|
Unit = {
|
||||||
|
Description = "Timer that starts nix-index every two hours";
|
||||||
|
PartOf = [ "nix-index.service" ];
|
||||||
|
};
|
||||||
|
Timer = {
|
||||||
|
OnCalendar = "00/2:30";
|
||||||
|
};
|
||||||
|
Install = {
|
||||||
|
WantedBy = [ "default.target" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
25
configurations/nix-store.nix
Normal file
25
configurations/nix-store.nix
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
nix = {
|
||||||
|
gc = {
|
||||||
|
automatic = true;
|
||||||
|
dates = "hourly";
|
||||||
|
options = "--delete-older-than 7d";
|
||||||
|
};
|
||||||
|
optimise = {
|
||||||
|
automatic = true;
|
||||||
|
dates = [ "hourly" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
system.autoUpgrade = {
|
||||||
|
allowReboot = false;
|
||||||
|
enable = true;
|
||||||
|
dates = "hourly";
|
||||||
|
};
|
||||||
|
|
||||||
|
home-manager.users.charlotte = { ... }: {
|
||||||
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,9 +1,9 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
imports = [ ../base-x/default.nix ];
|
imports = [ ./base-x.nix ];
|
||||||
home-manager.users.charlotte = { pkgs, ... }: {
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
xdg.configFile."openbox/rc.xml".source = ./rc.xml;
|
xdg.configFile."openbox/rc.xml".source = ./openbox/rc.xml;
|
||||||
xsession = {
|
xsession = {
|
||||||
windowManager.command = "${pkgs.openbox}/bin/openbox";
|
windowManager.command = "${pkgs.openbox}/bin/openbox";
|
||||||
initExtra = ''
|
initExtra = ''
|
15
configurations/sound.nix
Normal file
15
configurations/sound.nix
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
custom.zfs.systemLinks = [
|
||||||
|
{ path = "/var/lib/pulse"; type = "data"; }
|
||||||
|
];
|
||||||
|
|
||||||
|
sound.enable = true;
|
||||||
|
hardware.pulseaudio = {
|
||||||
|
enable = true;
|
||||||
|
systemWide = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
users.users.charlotte.extraGroups = [ "audio" ];
|
||||||
|
}
|
|
@ -1,7 +1,16 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
home-manager.users.charlotte = { ... }: {
|
imports = [ ./ssh/secret.nix ];
|
||||||
|
|
||||||
|
custom.zfs.homeLinks = [
|
||||||
|
{ path = ".ssh/known_hosts"; type = "cache"; }
|
||||||
|
];
|
||||||
|
|
||||||
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
ssh
|
||||||
|
];
|
||||||
programs.ssh = {
|
programs.ssh = {
|
||||||
enable = true;
|
enable = true;
|
||||||
compression = true;
|
compression = true;
|
BIN
configurations/ssh/secret.nix
Normal file
BIN
configurations/ssh/secret.nix
Normal file
Binary file not shown.
|
@ -1,16 +1,12 @@
|
||||||
with import <nixpkgs> { };
|
|
||||||
{ pkgs, ... }:
|
{ pkgs, ... }:
|
||||||
let
|
let
|
||||||
firefox = import ../../programs/firefox/default.nix { inherit pkgs; };
|
launcher = import ./sway/launcher.nix { inherit pkgs; stdenv = pkgs.stdenv; };
|
||||||
launcher = import ./launcher.nix { inherit pkgs stdenv; };
|
color-picker = import ./sway/color-picker.nix { inherit pkgs; };
|
||||||
color-picker = import ./color-picker.nix { inherit pkgs; };
|
screenshot = import ./sway/screenshot.nix { inherit pkgs; };
|
||||||
screenshot = import ./screenshot.nix { inherit pkgs; };
|
status-configuration = import ./sway/status-configuration.nix { inherit pkgs; };
|
||||||
status-configuration = import ./status-configuration.nix { inherit pkgs; };
|
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [ ./sway/kanshi.nix ];
|
||||||
./kanshi.nix
|
|
||||||
];
|
|
||||||
programs = {
|
programs = {
|
||||||
sway = {
|
sway = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -92,7 +88,7 @@ in
|
||||||
### Startup programs
|
### Startup programs
|
||||||
#
|
#
|
||||||
workspace 1
|
workspace 1
|
||||||
exec ${firefox}/bin/firefox
|
exec ${pkgs.firefox}/bin/firefox
|
||||||
workspace 3
|
workspace 3
|
||||||
exec ${pkgs.thunderbird}/bin/thunderbird
|
exec ${pkgs.thunderbird}/bin/thunderbird
|
||||||
workspace 4
|
workspace 4
|
|
@ -1,6 +1,5 @@
|
||||||
{ pkgs, stdenv }:
|
{ pkgs, stdenv }:
|
||||||
let
|
let
|
||||||
pass = import ../../programs/pass/default.nix { inherit pkgs; };
|
|
||||||
gemoji = pkgs.buildRubyGem {
|
gemoji = pkgs.buildRubyGem {
|
||||||
pname = "gemoji";
|
pname = "gemoji";
|
||||||
gemName = "gemoji";
|
gemName = "gemoji";
|
||||||
|
@ -74,16 +73,16 @@ pkgs.writeScriptBin "launcher" ''
|
||||||
echo $passfile
|
echo $passfile
|
||||||
case $option in
|
case $option in
|
||||||
username)
|
username)
|
||||||
swaymsg exec -- "${pass}/bin/pass show '$passfile' | sed -n 's/^Username: *//p' | tr -d '\n' | ${pkgs.wl-clipboard}/bin/wl-copy --foreground"
|
swaymsg exec -- "${pkgs.pass}/bin/pass show '$passfile' | sed -n 's/^Username: *//p' | tr -d '\n' | ${pkgs.wl-clipboard}/bin/wl-copy --foreground"
|
||||||
;;
|
;;
|
||||||
password)
|
password)
|
||||||
swaymsg exec -- "${pass}/bin/pass show -c0 '$passfile'"
|
swaymsg exec -- "${pkgs.pass}/bin/pass show -c0 '$passfile'"
|
||||||
;;
|
;;
|
||||||
otp)
|
otp)
|
||||||
swaymsg exec -- "${pass}/bin/pass otp -c '$passfile'"
|
swaymsg exec -- "${pkgs.pass}/bin/pass otp -c '$passfile'"
|
||||||
;;
|
;;
|
||||||
edit)
|
edit)
|
||||||
${pass}/bin/pass edit "$passfile"
|
${pkgs.pass}/bin/pass edit "$passfile"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
|
|
11
configurations/syncthing.nix
Normal file
11
configurations/syncthing.nix
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
custom.zfs.homeLinks = [
|
||||||
|
{ path = ".config/syncthing"; type = "data"; }
|
||||||
|
{ path = "sync"; type = "data"; }
|
||||||
|
];
|
||||||
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
|
services.syncthing.enable = true;
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,7 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
home-manager.users.charlotte = { pkgs, ... }: {
|
|
||||||
services.syncthing.enable = true;
|
|
||||||
};
|
|
||||||
}
|
|
11
configurations/teams.nix
Normal file
11
configurations/teams.nix
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
|
home.packages = with pkgs; [ teams ];
|
||||||
|
};
|
||||||
|
|
||||||
|
custom.zfs.homeLinks = [
|
||||||
|
{ path = ".config/Microsoft"; type = "data"; }
|
||||||
|
];
|
||||||
|
}
|
47
configurations/themes.nix
Normal file
47
configurations/themes.nix
Normal file
|
@ -0,0 +1,47 @@
|
||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
|
home.packages = [ pkgs.vanilla-dmz ];
|
||||||
|
home.file = {
|
||||||
|
".icons/default/index.theme".text = ''
|
||||||
|
[Icon Theme]
|
||||||
|
Name=Default
|
||||||
|
Comment=Default Cursor Theme
|
||||||
|
Inherits=Vanilla-DMZ
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
dconf.settings."org/gnome/desktop/interface" = {
|
||||||
|
gtk-theme = "Arc";
|
||||||
|
icon-theme = "Arc";
|
||||||
|
cursor-theme = "Vanilla-DMZ";
|
||||||
|
};
|
||||||
|
gtk = {
|
||||||
|
enable = true;
|
||||||
|
font = {
|
||||||
|
package = pkgs.noto-fonts;
|
||||||
|
name = "Noto Sans 10";
|
||||||
|
};
|
||||||
|
gtk2.extraConfig = ''
|
||||||
|
gtk-cursor-theme-name = "Vanilla-DMZ"
|
||||||
|
gtk-cursor-theme-size = 0
|
||||||
|
'';
|
||||||
|
gtk3.extraConfig = {
|
||||||
|
gtk-cursor-theme-name = "Vanilla-DMZ";
|
||||||
|
gtk-cursor-theme-size = 0;
|
||||||
|
};
|
||||||
|
iconTheme = {
|
||||||
|
package = pkgs.arc-icon-theme;
|
||||||
|
name = "Arc";
|
||||||
|
};
|
||||||
|
theme = {
|
||||||
|
package = pkgs.arc-theme;
|
||||||
|
name = "Arc";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
qt = {
|
||||||
|
enable = true;
|
||||||
|
platformTheme = "gtk";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
12
configurations/thunderbird.nix
Normal file
12
configurations/thunderbird.nix
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
|
home.packages = with pkgs; [ thunderbird ];
|
||||||
|
};
|
||||||
|
|
||||||
|
custom.zfs.homeLinks = [
|
||||||
|
{ path = ".cache/thunderbird"; type = "cache"; }
|
||||||
|
{ path = ".thunderbird"; type = "data"; }
|
||||||
|
];
|
||||||
|
}
|
|
@ -17,8 +17,8 @@
|
||||||
tmuxinator.enable = true;
|
tmuxinator.enable = true;
|
||||||
};
|
};
|
||||||
xdg.configFile = {
|
xdg.configFile = {
|
||||||
"tmuxinator/accentor.yml".source = ./accentor.yml;
|
"tmuxinator/accentor.yml".source = ./tmux/accentor.yml;
|
||||||
"tmuxinator/dodona.yml".source = ./dodona.yml;
|
"tmuxinator/dodona.yml".source = ./tmux/dodona.yml;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
23
configurations/users.nix
Normal file
23
configurations/users.nix
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
imports = [ ./users/secret.nix ];
|
||||||
|
|
||||||
|
users = {
|
||||||
|
mutableUsers = false;
|
||||||
|
defaultUserShell = pkgs.zsh;
|
||||||
|
users = {
|
||||||
|
charlotte = {
|
||||||
|
isNormalUser = true;
|
||||||
|
home = "/home/charlotte";
|
||||||
|
description = "Charlotte Van Petegem";
|
||||||
|
extraGroups = [
|
||||||
|
"input"
|
||||||
|
"systemd-journal"
|
||||||
|
"video"
|
||||||
|
"wheel"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
BIN
configurations/users/secret.nix
Normal file
BIN
configurations/users/secret.nix
Normal file
Binary file not shown.
32
configurations/xdg-dirs.nix
Normal file
32
configurations/xdg-dirs.nix
Normal file
|
@ -0,0 +1,32 @@
|
||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
custom.zfs.homeLinks = [
|
||||||
|
{ path = "desktop"; type = "data"; }
|
||||||
|
{ path = "documents"; type = "data"; }
|
||||||
|
{ path = "downloads"; type = "data"; }
|
||||||
|
{ path = "music"; type = "data"; }
|
||||||
|
{ path = "pictures"; type = "data"; }
|
||||||
|
{ path = "repos"; type = "data"; }
|
||||||
|
{ path = "templates"; type = "data"; }
|
||||||
|
{ path = "videos"; type = "data"; }
|
||||||
|
];
|
||||||
|
|
||||||
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
|
home.packages = with pkgs; [ xdg-user-dirs ];
|
||||||
|
xdg = {
|
||||||
|
enable = true;
|
||||||
|
userDirs = {
|
||||||
|
enable = true;
|
||||||
|
desktop = "\$HOME/desktop";
|
||||||
|
documents = "\$HOME/documents";
|
||||||
|
download = "\$HOME/downloads";
|
||||||
|
music = "\$HOME/music";
|
||||||
|
pictures = "\$HOME/pictures";
|
||||||
|
publicShare = "\$HOME/desktop";
|
||||||
|
templates = "\$HOME/templates";
|
||||||
|
videos = "\$HOME/videos";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,6 +1,10 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
|
custom.zfs.homeLinks = [
|
||||||
|
{ path = ".local/share/autojump"; type = "cache"; }
|
||||||
|
{ path = ".local/share/zsh"; type = "cache"; }
|
||||||
|
];
|
||||||
home-manager.users.charlotte = { pkgs, ... }: {
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
home.packages = [ pkgs.autojump ];
|
home.packages = [ pkgs.autojump ];
|
||||||
programs.zsh = {
|
programs.zsh = {
|
||||||
|
@ -10,7 +14,7 @@
|
||||||
dotDir = ".config/zsh";
|
dotDir = ".config/zsh";
|
||||||
history = {
|
history = {
|
||||||
expireDuplicatesFirst = true;
|
expireDuplicatesFirst = true;
|
||||||
path = "\$HOME/.config/zsh/zsh_history";
|
path = "\$HOME/.local/share/zsh/history";
|
||||||
};
|
};
|
||||||
initExtra = ''
|
initExtra = ''
|
||||||
source ${pkgs.nix-index}/etc/profile.d/command-not-found.sh
|
source ${pkgs.nix-index}/etc/profile.d/command-not-found.sh
|
|
@ -1,21 +1,28 @@
|
||||||
{ config, pkgs, ... }:
|
{ pkgs, lib, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
<home-manager/nixos>
|
<home-manager/nixos>
|
||||||
./hardware.nix
|
./hardware.nix
|
||||||
./secret.nix
|
./secret.nix
|
||||||
|
../../configurations/eid.nix
|
||||||
../../profiles/bluetooth/default.nix
|
../../profiles/bluetooth/default.nix
|
||||||
../../profiles/common/default.nix
|
../../profiles/common/default.nix
|
||||||
../../profiles/graphical/default.nix
|
../../profiles/graphical/default.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
boot.loader = {
|
# Use the systemd-boot EFI boot loader.
|
||||||
|
boot = {
|
||||||
|
loader = {
|
||||||
systemd-boot.enable = true;
|
systemd-boot.enable = true;
|
||||||
efi.canTouchEfiVariables = true;
|
efi.canTouchEfiVariables = true;
|
||||||
};
|
};
|
||||||
|
};
|
||||||
|
|
||||||
networking.hostName = "pentos";
|
networking = {
|
||||||
|
hostId = "3cc1a4b2";
|
||||||
|
hostName = "kholinar";
|
||||||
|
};
|
||||||
|
|
||||||
time.timeZone = "Europe/Brussels";
|
time.timeZone = "Europe/Brussels";
|
||||||
|
|
||||||
|
@ -25,14 +32,18 @@
|
||||||
# this value at the release version of the first install of this system.
|
# this value at the release version of the first install of this system.
|
||||||
# Before changing this value read the documentation for this option
|
# Before changing this value read the documentation for this option
|
||||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||||
system.stateVersion = "20.03";
|
system.stateVersion = "20.09";
|
||||||
|
|
||||||
home-manager.users.charlotte = { ... }: {
|
home-manager.users.charlotte = { ... }: {
|
||||||
home.stateVersion = "20.03";
|
home.stateVersion = "20.09";
|
||||||
};
|
};
|
||||||
|
|
||||||
# Machine-specific application settings
|
# Machine-specific settings
|
||||||
custom = {
|
custom = {
|
||||||
git.email = "charlotte@vanpetegem.me";
|
git.email = "charlotte@vanpetegem.me";
|
||||||
|
zfs = {
|
||||||
|
enable = true;
|
||||||
|
encrypted = true;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
48
machines/kholinar/hardware.nix
Normal file
48
machines/kholinar/hardware.nix
Normal file
|
@ -0,0 +1,48 @@
|
||||||
|
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||||
|
# and may be overwritten by future invocations. Please make changes
|
||||||
|
# to /etc/nixos/configuration.nix instead.
|
||||||
|
{ config, lib, pkgs, modulesPath, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
||||||
|
|
||||||
|
boot.initrd.availableKernelModules = [ "xhci_pci" "nvme" "usbhid" "usb_storage" "sd_mod" "sdhci_pci" ];
|
||||||
|
boot.initrd.kernelModules = [ "i915" ];
|
||||||
|
boot.kernelModules = [ "kvm-intel" ];
|
||||||
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
|
fileSystems."/" = {
|
||||||
|
device = "rpool/local/root";
|
||||||
|
fsType = "zfs";
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/nix" = {
|
||||||
|
device = "rpool/local/nix";
|
||||||
|
fsType = "zfs";
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/data" = {
|
||||||
|
device = "rpool/safe/data";
|
||||||
|
fsType = "zfs";
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/cache" = {
|
||||||
|
device = "rpool/local/cache";
|
||||||
|
fsType = "zfs";
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
fileSystems."/boot" = {
|
||||||
|
device = "/dev/disk/by-uuid/BEEE-D83A";
|
||||||
|
fsType = "vfat";
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
swapDevices = [
|
||||||
|
{ device = "/dev/disk/by-uuid/6c09b90f-8971-4702-a18a-f06dfb3d8dcd"; }
|
||||||
|
];
|
||||||
|
|
||||||
|
nix.maxJobs = lib.mkDefault 8;
|
||||||
|
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
||||||
|
hardware.cpu.intel.updateMicrocode = true;
|
||||||
|
}
|
BIN
machines/kholinar/secret.nix
Normal file
BIN
machines/kholinar/secret.nix
Normal file
Binary file not shown.
|
@ -5,6 +5,7 @@
|
||||||
<home-manager/nixos>
|
<home-manager/nixos>
|
||||||
./hardware.nix
|
./hardware.nix
|
||||||
./secret.nix
|
./secret.nix
|
||||||
|
../../configurations/eid.nix
|
||||||
../../profiles/bluetooth/default.nix
|
../../profiles/bluetooth/default.nix
|
||||||
../../profiles/common/default.nix
|
../../profiles/common/default.nix
|
||||||
../../profiles/graphical/default.nix
|
../../profiles/graphical/default.nix
|
||||||
|
|
|
@ -1,29 +0,0 @@
|
||||||
{ config, lib, pkgs, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
imports = [ <nixpkgs/nixos/modules/installer/scan/not-detected.nix> ];
|
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [ "xhci_pci" "nvme" "usbhid" "usb_storage" "sd_mod" "sr_mod" ];
|
|
||||||
# Early KMS start
|
|
||||||
boot.initrd.kernelModules = [ "i915" ];
|
|
||||||
boot.kernelModules = [ "kvm-intel" ];
|
|
||||||
boot.extraModulePackages = [ ];
|
|
||||||
|
|
||||||
fileSystems."/" = {
|
|
||||||
device = "/dev/disk/by-uuid/0eb8b94a-5fc2-4b24-962a-94b3675b6f5b";
|
|
||||||
fsType = "ext4";
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/boot" = {
|
|
||||||
device = "/dev/disk/by-uuid/46AC-2E2E";
|
|
||||||
fsType = "vfat";
|
|
||||||
};
|
|
||||||
|
|
||||||
swapDevices = [
|
|
||||||
{ device = "/dev/disk/by-uuid/b8f6154e-6b1f-42d7-8fe0-c03d7ad150f3"; }
|
|
||||||
];
|
|
||||||
|
|
||||||
nix.maxJobs = lib.mkDefault 8;
|
|
||||||
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
|
||||||
hardware.cpu.intel.updateMicrocode = true;
|
|
||||||
}
|
|
Binary file not shown.
56
modules/zfs.nix
Normal file
56
modules/zfs.nix
Normal file
|
@ -0,0 +1,56 @@
|
||||||
|
{ config, lib, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
options.custom.zfs = {
|
||||||
|
enable = lib.mkOption {
|
||||||
|
default = false;
|
||||||
|
example = true;
|
||||||
|
};
|
||||||
|
encrypted = lib.mkOption {
|
||||||
|
default = false;
|
||||||
|
example = true;
|
||||||
|
};
|
||||||
|
systemLinks = lib.mkOption {
|
||||||
|
default = [ ];
|
||||||
|
example = [
|
||||||
|
{ path = "/var/lib/docker"; type = "cache"; }
|
||||||
|
{ path = "/var/lib/docker/volumes"; type = "data"; }
|
||||||
|
];
|
||||||
|
};
|
||||||
|
homeLinks = lib.mkOption {
|
||||||
|
default = [ ];
|
||||||
|
example = [
|
||||||
|
{ path = ".config/syncthing"; type = "data"; }
|
||||||
|
{ path = ".cache/nix-index"; type = "cache"; }
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config.boot = lib.mkIf config.custom.zfs.enable {
|
||||||
|
supportedFilesystems = [ "zfs" ];
|
||||||
|
zfs.requestEncryptionCredentials = config.custom.zfs.encrypted;
|
||||||
|
initrd.postDeviceCommands = lib.mkAfter ''
|
||||||
|
zfs rollback -r rpool/local/root@blank
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
config.services.zfs.autoScrub.enable = config.custom.zfs.enable;
|
||||||
|
config.services.zfs.trim.enable = config.custom.zfs.enable;
|
||||||
|
|
||||||
|
config.environment.etc = lib.mkIf config.custom.zfs.enable {
|
||||||
|
nixos = { source = "/data/etc/nixos/"; };
|
||||||
|
};
|
||||||
|
|
||||||
|
config.systemd.tmpfiles.rules = lib.mkIf config.custom.zfs.enable (
|
||||||
|
[ "d /home/charlotte 0700 charlotte users - -" ] ++
|
||||||
|
(map (location: "L ${location.path} - - - - /${location.type}${location.path}") config.custom.zfs.systemLinks)
|
||||||
|
);
|
||||||
|
|
||||||
|
config.home-manager.users.charlotte = { ... }: {
|
||||||
|
systemd.user.tmpfiles.rules = lib.mkIf config.custom.zfs.enable (
|
||||||
|
map
|
||||||
|
(location: "L /home/charlotte/${location.path} - - - - /${location.type}/home/charlotte/${location.path}")
|
||||||
|
config.custom.zfs.homeLinks
|
||||||
|
);
|
||||||
|
};
|
||||||
|
}
|
14
overlays/default.nix
Normal file
14
overlays/default.nix
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
{ ... }:
|
||||||
|
let
|
||||||
|
overlays = [
|
||||||
|
(import ./pass.nix)
|
||||||
|
(import ./ssh.nix)
|
||||||
|
];
|
||||||
|
in
|
||||||
|
{
|
||||||
|
nixpkgs.overlays = overlays;
|
||||||
|
|
||||||
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
|
nixpkgs.overlays = overlays;
|
||||||
|
};
|
||||||
|
}
|
4
overlays/pass.nix
Normal file
4
overlays/pass.nix
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
self: super: {
|
||||||
|
firefox = super.firefox.override { extraNativeMessagingHosts = [ self.passff-host ]; };
|
||||||
|
pass = (super.pass-wayland.override { pass = super.pass-wayland; }).withExtensions (ext: [ ext.pass-otp ]);
|
||||||
|
}
|
16
overlays/ssh.nix
Normal file
16
overlays/ssh.nix
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
self: super: {
|
||||||
|
ssh = self.symlinkJoin {
|
||||||
|
name = "openssh";
|
||||||
|
paths = [
|
||||||
|
(
|
||||||
|
self.writeScriptBin "ssh" ''
|
||||||
|
#!${self.zsh}/bin/zsh
|
||||||
|
|
||||||
|
export TERM=xterm-256color
|
||||||
|
${super.openssh}/bin/ssh $@
|
||||||
|
''
|
||||||
|
)
|
||||||
|
super.openssh
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
|
@ -84,8 +84,7 @@ let
|
||||||
(id: "${replaceStrings [ "." ] [ "/" ] id.group}/${id.name}/maven-metadata.xml")
|
(id: "${replaceStrings [ "." ] [ "/" ] id.group}/${id.name}/maven-metadata.xml")
|
||||||
ids;
|
ids;
|
||||||
in
|
in
|
||||||
attrValues
|
attrValues (
|
||||||
(
|
|
||||||
mapAttrs
|
mapAttrs
|
||||||
(
|
(
|
||||||
path: meta:
|
path: meta:
|
||||||
|
@ -106,7 +105,8 @@ let
|
||||||
</versioning>
|
</versioning>
|
||||||
</metadata>
|
</metadata>
|
||||||
''
|
''
|
||||||
) modules
|
)
|
||||||
|
modules
|
||||||
);
|
);
|
||||||
mkSnapshotMetadata = deps:
|
mkSnapshotMetadata = deps:
|
||||||
let
|
let
|
||||||
|
@ -156,8 +156,7 @@ let
|
||||||
</snapshotVersion>
|
</snapshotVersion>
|
||||||
'';
|
'';
|
||||||
in
|
in
|
||||||
attrValues
|
attrValues (
|
||||||
(
|
|
||||||
mapAttrs
|
mapAttrs
|
||||||
(
|
(
|
||||||
path: meta:
|
path: meta:
|
||||||
|
@ -179,7 +178,8 @@ let
|
||||||
</versioning>
|
</versioning>
|
||||||
</metadata>
|
</metadata>
|
||||||
''
|
''
|
||||||
) modules
|
)
|
||||||
|
modules
|
||||||
);
|
);
|
||||||
mkRepo = project: type: deps: buildEnv {
|
mkRepo = project: type: deps: buildEnv {
|
||||||
name = "${project}-gradle-${type}-env";
|
name = "${project}-gradle-${type}-env";
|
||||||
|
@ -248,8 +248,7 @@ let
|
||||||
pname = args.pname or projectEnv.name;
|
pname = args.pname or projectEnv.name;
|
||||||
version = args.version or projectEnv.version;
|
version = args.version or projectEnv.version;
|
||||||
in
|
in
|
||||||
stdenv.mkDerivation
|
stdenv.mkDerivation (
|
||||||
(
|
|
||||||
args // {
|
args // {
|
||||||
|
|
||||||
inherit pname version;
|
inherit pname version;
|
||||||
|
|
|
@ -5,7 +5,8 @@ let
|
||||||
python = if nodejs ? python then nodejs.python else python2;
|
python = if nodejs ? python then nodejs.python else python2;
|
||||||
|
|
||||||
# Create a tar wrapper that filters all the 'Ignoring unknown extended header keyword' noise
|
# Create a tar wrapper that filters all the 'Ignoring unknown extended header keyword' noise
|
||||||
tarWrapper = runCommand "tarWrapper" { } ''
|
tarWrapper = runCommand "tarWrapper"
|
||||||
|
{ } ''
|
||||||
mkdir -p $out/bin
|
mkdir -p $out/bin
|
||||||
|
|
||||||
cat > $out/bin/tar <<EOF
|
cat > $out/bin/tar <<EOF
|
||||||
|
@ -36,7 +37,8 @@ let
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
includeDependencies = { dependencies }:
|
includeDependencies = { dependencies }:
|
||||||
stdenv.lib.optionalString (dependencies != [ ])
|
stdenv.lib.optionalString
|
||||||
|
(dependencies != [ ])
|
||||||
(stdenv.lib.concatMapStrings
|
(stdenv.lib.concatMapStrings
|
||||||
(dependency:
|
(dependency:
|
||||||
''
|
''
|
||||||
|
@ -52,7 +54,9 @@ let
|
||||||
|
|
||||||
cd ..
|
cd ..
|
||||||
''
|
''
|
||||||
) dependencies);
|
)
|
||||||
|
dependencies
|
||||||
|
);
|
||||||
|
|
||||||
# Recursively composes the dependencies of a package
|
# Recursively composes the dependencies of a package
|
||||||
composePackage = { name, packageName, src, dependencies ? [ ], ... }@args:
|
composePackage = { name, packageName, src, dependencies ? [ ], ... }@args:
|
||||||
|
@ -186,7 +190,8 @@ let
|
||||||
|
|
||||||
# Extract the Node.js source code which is used to compile packages with
|
# Extract the Node.js source code which is used to compile packages with
|
||||||
# native bindings
|
# native bindings
|
||||||
nodeSources = runCommand "node-sources" { } ''
|
nodeSources = runCommand "node-sources"
|
||||||
|
{ } ''
|
||||||
tar --no-same-owner --no-same-permissions -xf ${nodejs.src}
|
tar --no-same-owner --no-same-permissions -xf ${nodejs.src}
|
||||||
mv node-* $out
|
mv node-* $out
|
||||||
'';
|
'';
|
||||||
|
@ -389,8 +394,7 @@ let
|
||||||
let
|
let
|
||||||
extraArgs = removeAttrs args [ "name" "dependencies" "buildInputs" "dontStrip" "dontNpmInstall" "preRebuild" "unpackPhase" "buildPhase" ];
|
extraArgs = removeAttrs args [ "name" "dependencies" "buildInputs" "dontStrip" "dontNpmInstall" "preRebuild" "unpackPhase" "buildPhase" ];
|
||||||
in
|
in
|
||||||
stdenv.mkDerivation
|
stdenv.mkDerivation ({
|
||||||
({
|
|
||||||
name = "node_${name}-${version}";
|
name = "node_${name}-${version}";
|
||||||
buildInputs = [ tarWrapper python nodejs ]
|
buildInputs = [ tarWrapper python nodejs ]
|
||||||
++ stdenv.lib.optional (stdenv.isLinux) utillinux
|
++ stdenv.lib.optional (stdenv.isLinux) utillinux
|
||||||
|
@ -462,8 +466,7 @@ let
|
||||||
}@args:
|
}@args:
|
||||||
let
|
let
|
||||||
extraArgs = removeAttrs args [ "name" "dependencies" "buildInputs" ];
|
extraArgs = removeAttrs args [ "name" "dependencies" "buildInputs" ];
|
||||||
nodeDependencies = stdenv.mkDerivation
|
nodeDependencies = stdenv.mkDerivation ({
|
||||||
({
|
|
||||||
name = "node-dependencies-${name}-${version}";
|
name = "node-dependencies-${name}-${version}";
|
||||||
|
|
||||||
buildInputs = [ tarWrapper python nodejs ]
|
buildInputs = [ tarWrapper python nodejs ]
|
||||||
|
|
|
@ -2,102 +2,30 @@
|
||||||
|
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./secret.nix
|
../../modules/zfs.nix
|
||||||
../../configurations/direnv/default.nix
|
../../overlays/default.nix
|
||||||
../../configurations/git/default.nix
|
../../configurations/direnv.nix
|
||||||
../../configurations/neovim/default.nix
|
../../configurations/git.nix
|
||||||
../../configurations/ssh/default.nix
|
../../configurations/locale.nix
|
||||||
../../configurations/tmux/default.nix
|
../../configurations/neovim.nix
|
||||||
../../configurations/zsh/default.nix
|
../../configurations/nix-index.nix
|
||||||
|
../../configurations/nix-store.nix
|
||||||
|
../../configurations/ssh.nix
|
||||||
|
../../configurations/tmux.nix
|
||||||
|
../../configurations/users.nix
|
||||||
|
../../configurations/zsh.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
# Use latest kernel
|
|
||||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
|
||||||
|
|
||||||
i18n = {
|
|
||||||
defaultLocale = "en_IE.UTF-8";
|
|
||||||
extraLocaleSettings = {
|
|
||||||
LC_TIME = "en_GB.UTF-8";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
console = {
|
|
||||||
font = "Lat2-Terminus16";
|
|
||||||
keyMap = "us";
|
|
||||||
};
|
|
||||||
|
|
||||||
nix = {
|
|
||||||
trustedUsers = [ "@wheel" ];
|
|
||||||
gc = {
|
|
||||||
automatic = true;
|
|
||||||
dates = "hourly";
|
|
||||||
options = "--delete-older-than 7d";
|
|
||||||
};
|
|
||||||
optimise = {
|
|
||||||
automatic = true;
|
|
||||||
dates = [ "hourly" ];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
home-manager.users.charlotte = { pkgs, ... }: {
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
htop
|
htop
|
||||||
inotify-tools
|
moreutils
|
||||||
ncdu
|
ncdu
|
||||||
nix-index
|
pass
|
||||||
(import ../../programs/pass/default.nix { inherit pkgs; })
|
|
||||||
(import ../../programs/ssh/default.nix { inherit pkgs; })
|
|
||||||
ripgrep
|
ripgrep
|
||||||
unzip
|
unzip
|
||||||
youtube-dl
|
youtube-dl
|
||||||
];
|
];
|
||||||
systemd.user = {
|
|
||||||
services.nix-index = {
|
|
||||||
Unit = {
|
|
||||||
Description = "Service to run nix-index";
|
|
||||||
};
|
|
||||||
Service = {
|
|
||||||
Type = "oneshot";
|
|
||||||
ExecStart = "${pkgs.nix-index}/bin/nix-index";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
timers.nix-index = {
|
|
||||||
Unit = {
|
|
||||||
Description = "Timer that starts nix-index every two hours";
|
|
||||||
PartOf = [ "nix-index.service" ];
|
|
||||||
};
|
|
||||||
Timer = {
|
|
||||||
OnCalendar = "00/2:30";
|
|
||||||
};
|
|
||||||
Install = {
|
|
||||||
WantedBy = [ "default.target" ];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
services.locate = {
|
|
||||||
enable = true;
|
|
||||||
interval = "hourly";
|
|
||||||
localuser = "charlotte";
|
|
||||||
};
|
|
||||||
|
|
||||||
system.autoUpgrade = {
|
|
||||||
allowReboot = false;
|
|
||||||
enable = true;
|
|
||||||
dates = "hourly";
|
|
||||||
};
|
|
||||||
|
|
||||||
users = {
|
|
||||||
mutableUsers = false;
|
|
||||||
defaultUserShell = pkgs.zsh;
|
|
||||||
users = {
|
|
||||||
charlotte = {
|
|
||||||
isNormalUser = true;
|
|
||||||
home = "/home/charlotte";
|
|
||||||
description = "Charlotte Van Petegem";
|
|
||||||
extraGroups = [ "wheel" ];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
Binary file not shown.
|
@ -2,106 +2,46 @@
|
||||||
|
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./secret.nix
|
../../configurations/adb.nix
|
||||||
../../configurations/dropbox/default.nix
|
../../configurations/docker.nix
|
||||||
../../configurations/i3/default.nix
|
../../configurations/dropbox.nix
|
||||||
../../configurations/kitty/default.nix
|
../../configurations/firefox.nix
|
||||||
../../configurations/syncthing/default.nix
|
../../configurations/fonts.nix
|
||||||
../../configurations/sway/default.nix
|
../../configurations/gnupg.nix
|
||||||
|
../../configurations/i3.nix
|
||||||
|
../../configurations/joplin.nix
|
||||||
|
../../configurations/kernel.nix
|
||||||
|
../../configurations/kitty.nix
|
||||||
|
../../configurations/mounts.nix
|
||||||
|
../../configurations/networkmanager.nix
|
||||||
|
../../configurations/sound.nix
|
||||||
|
../../configurations/sway.nix
|
||||||
|
../../configurations/syncthing.nix
|
||||||
|
../../configurations/teams.nix
|
||||||
|
../../configurations/themes.nix
|
||||||
|
../../configurations/thunderbird.nix
|
||||||
|
../../configurations/xdg-dirs.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
services.pcscd = {
|
|
||||||
enable = true;
|
|
||||||
plugins = [ pkgs.ccid ];
|
|
||||||
};
|
|
||||||
|
|
||||||
sound.enable = true;
|
|
||||||
hardware.pulseaudio.enable = true;
|
|
||||||
|
|
||||||
fonts = {
|
|
||||||
enableFontDir = true;
|
|
||||||
fontconfig = {
|
|
||||||
enable = true;
|
|
||||||
defaultFonts = {
|
|
||||||
emoji = [ "Noto Color Emoji" ];
|
|
||||||
monospace = [ "Fira Code" ];
|
|
||||||
sansSerif = [ "Noto Sans" ];
|
|
||||||
serif = [ "Noto Serif" ];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
fonts = with pkgs; [
|
|
||||||
fira-code
|
|
||||||
fira-code-symbols
|
|
||||||
font-awesome_4
|
|
||||||
noto-fonts
|
|
||||||
noto-fonts-cjk
|
|
||||||
noto-fonts-emoji
|
|
||||||
noto-fonts-extra
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
networking = {
|
|
||||||
hosts = { "127.0.0.1" = [ "dodona.localhost" "sandbox.localhost" ]; };
|
|
||||||
networkmanager = {
|
|
||||||
enable = true;
|
|
||||||
packages = [ pkgs.networkmanager-vpnc ];
|
|
||||||
wifi.macAddress = "random";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
virtualisation.docker.enable = true;
|
|
||||||
|
|
||||||
users.users.charlotte.extraGroups = [
|
|
||||||
"adbusers"
|
|
||||||
"docker"
|
|
||||||
"input"
|
|
||||||
"networkmanager"
|
|
||||||
"video"
|
|
||||||
];
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [ eid-mw ];
|
|
||||||
|
|
||||||
programs.adb.enable = true;
|
|
||||||
|
|
||||||
home-manager.users.charlotte = { pkgs, ... }: {
|
home-manager.users.charlotte = { pkgs, ... }: {
|
||||||
nixpkgs.config.allowUnfree = true;
|
home.packages = with pkgs; [
|
||||||
home = {
|
|
||||||
packages = with pkgs; [
|
|
||||||
chromium
|
chromium
|
||||||
citrix_workspace
|
citrix_workspace
|
||||||
deluge
|
deluge
|
||||||
(import ../../programs/firefox/default.nix { inherit pkgs; })
|
|
||||||
(import ../../programs/gnupg/default.nix { inherit pkgs; })
|
|
||||||
google-chrome
|
google-chrome
|
||||||
hledger
|
hledger
|
||||||
joplin-desktop
|
|
||||||
libreoffice
|
libreoffice
|
||||||
moreutils
|
|
||||||
mpv
|
mpv
|
||||||
mumble
|
mumble
|
||||||
networkmanagerapplet
|
|
||||||
okular
|
okular
|
||||||
pavucontrol
|
pavucontrol
|
||||||
ranger
|
ranger
|
||||||
slurp
|
slurp
|
||||||
sshfs
|
sshfs
|
||||||
teams
|
|
||||||
thunderbird
|
|
||||||
vanilla-dmz
|
|
||||||
wf-recorder
|
wf-recorder
|
||||||
wl-clipboard
|
wl-clipboard
|
||||||
xdg-user-dirs
|
|
||||||
zeroad
|
zeroad
|
||||||
];
|
];
|
||||||
file = {
|
|
||||||
".icons/default/index.theme".text = ''
|
|
||||||
[Icon Theme]
|
|
||||||
Name=Default
|
|
||||||
Comment=Default Cursor Theme
|
|
||||||
Inherits=Vanilla-DMZ
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
programs.zsh.loginExtra = ''
|
programs.zsh.loginExtra = ''
|
||||||
if [[ -z "$DISPLAY" ]] && [[ $(tty) = "/dev/tty1" ]]; then
|
if [[ -z "$DISPLAY" ]] && [[ $(tty) = "/dev/tty1" ]]; then
|
||||||
exec sway
|
exec sway
|
||||||
|
@ -111,53 +51,5 @@
|
||||||
exec startx
|
exec startx
|
||||||
fi
|
fi
|
||||||
'';
|
'';
|
||||||
dconf.settings = {
|
|
||||||
"org/gnome/desktop/interface" = {
|
|
||||||
gtk-theme = "Arc";
|
|
||||||
icon-theme = "Arc";
|
|
||||||
cursor-theme = "Vanilla-DMZ";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
gtk = {
|
|
||||||
enable = true;
|
|
||||||
font = {
|
|
||||||
package = pkgs.noto-fonts;
|
|
||||||
name = "Noto Sans 10";
|
|
||||||
};
|
|
||||||
gtk2.extraConfig = ''
|
|
||||||
gtk-cursor-theme-name = "Vanilla-DMZ"
|
|
||||||
gtk-cursor-theme-size = 0
|
|
||||||
'';
|
|
||||||
gtk3.extraConfig = {
|
|
||||||
gtk-cursor-theme-name = "Vanilla-DMZ";
|
|
||||||
gtk-cursor-theme-size = 0;
|
|
||||||
};
|
|
||||||
iconTheme = {
|
|
||||||
package = pkgs.arc-icon-theme;
|
|
||||||
name = "Arc";
|
|
||||||
};
|
|
||||||
theme = {
|
|
||||||
package = pkgs.arc-theme;
|
|
||||||
name = "Arc";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
qt = {
|
|
||||||
enable = true;
|
|
||||||
platformTheme = "gtk";
|
|
||||||
};
|
|
||||||
xdg = {
|
|
||||||
enable = true;
|
|
||||||
userDirs = {
|
|
||||||
enable = true;
|
|
||||||
desktop = "\$HOME/desktop";
|
|
||||||
documents = "\$HOME/documents";
|
|
||||||
download = "\$HOME/downloads";
|
|
||||||
music = "\$HOME/music";
|
|
||||||
pictures = "\$HOME/pictures";
|
|
||||||
publicShare = "\$HOME/desktop";
|
|
||||||
templates = "\$HOME/templates";
|
|
||||||
videos = "\$HOME/videos";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Binary file not shown.
|
@ -1,7 +0,0 @@
|
||||||
{ pkgs }:
|
|
||||||
|
|
||||||
(pkgs.firefox.override {
|
|
||||||
extraNativeMessagingHosts = [
|
|
||||||
(pkgs.passff-host.override { pass = (import ../../programs/pass/default.nix { inherit pkgs; }); })
|
|
||||||
];
|
|
||||||
})
|
|
|
@ -1,3 +0,0 @@
|
||||||
{ pkgs }:
|
|
||||||
|
|
||||||
pkgs.gnupg.override { guiSupport = true; }
|
|
|
@ -1,3 +0,0 @@
|
||||||
{ pkgs }:
|
|
||||||
|
|
||||||
(pkgs.pass-wayland.override { pass = pkgs.pass-wayland; }).withExtensions (ext: [ ext.pass-otp ext.pass-genphrase ])
|
|
|
@ -1,16 +0,0 @@
|
||||||
{ pkgs }:
|
|
||||||
|
|
||||||
pkgs.symlinkJoin {
|
|
||||||
name = "openssh";
|
|
||||||
paths = [
|
|
||||||
(
|
|
||||||
pkgs.writeScriptBin "ssh" ''
|
|
||||||
#!${pkgs.zsh}/bin/zsh
|
|
||||||
|
|
||||||
export TERM=xterm-256color
|
|
||||||
${pkgs.openssh}/bin/ssh $@
|
|
||||||
''
|
|
||||||
)
|
|
||||||
pkgs.openssh
|
|
||||||
];
|
|
||||||
}
|
|
Loading…
Add table
Add a link
Reference in a new issue