mirror of
https://github.com/Ahwxorg/nixos-config.git
synced 2025-12-04 23:00:14 +01:00
Compare commits
7 commits
94b414bab9
...
0fa2dd54dc
| Author | SHA1 | Date | |
|---|---|---|---|
| 0fa2dd54dc | |||
| ee59ff3f3b | |||
| 1f06aba566 | |||
| 69a7d717d6 | |||
| 9c5f55644f | |||
| c2159bf950 | |||
| 58e4e735dc |
7 changed files with 207 additions and 16 deletions
6
flake.lock
generated
6
flake.lock
generated
|
|
@ -954,11 +954,11 @@
|
||||||
"nixvim": "nixvim_2"
|
"nixvim": "nixvim_2"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1753605519,
|
"lastModified": 1754172548,
|
||||||
"narHash": "sha256-RJTIXX9JMeUOA3sJuiqJRBXFzzQLM6GrOFrL8+Iy6hg=",
|
"narHash": "sha256-8lWMN23VGQHTN5Kg5Kz1UMakt42brOlMz2IKxFBvKog=",
|
||||||
"owner": "ahwxorg",
|
"owner": "ahwxorg",
|
||||||
"repo": "nixvim-config",
|
"repo": "nixvim-config",
|
||||||
"rev": "20053a4d7a90b56cb7fe38d9557d71aeecd2cb47",
|
"rev": "fe2f1c27fa532489800b8f4d17f12c13299afa8d",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
|
||||||
|
|
@ -14,6 +14,8 @@
|
||||||
"nix-command"
|
"nix-command"
|
||||||
"flakes"
|
"flakes"
|
||||||
];
|
];
|
||||||
|
# substituters = [ "http://violet.booping.local" ];
|
||||||
|
# trusted-public-keys = [ "violet.booping.local:2gshN3xfGSL7eKFc8tGkqSoIb3WQxuB2RJ8DuakLLqc=%" ];
|
||||||
};
|
};
|
||||||
gc = {
|
gc = {
|
||||||
automatic = true;
|
automatic = true;
|
||||||
|
|
@ -22,6 +24,11 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
programs.nix-ld = {
|
||||||
|
enable = true;
|
||||||
|
libraries = with pkgs; [ ];
|
||||||
|
};
|
||||||
|
|
||||||
# nixpkgs = {
|
# nixpkgs = {
|
||||||
# overlays = [
|
# overlays = [
|
||||||
# self.overlays.default
|
# self.overlays.default
|
||||||
|
|
@ -56,6 +63,6 @@
|
||||||
ipaexfont
|
ipaexfont
|
||||||
];
|
];
|
||||||
|
|
||||||
time.timeZone = "Europe/Amsterdam";
|
time.timeZone = lib.mkDefault "Europe/Amsterdam";
|
||||||
system.stateVersion = "24.05";
|
system.stateVersion = "24.05";
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
programs.kitty = {
|
programs.kitty = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
||||||
theme = "3024 Night";
|
# theme = "3024 Night";
|
||||||
|
|
||||||
font = {
|
font = {
|
||||||
name = "GohuFont 14 Nerd Font Mono";
|
name = "GohuFont 14 Nerd Font Mono";
|
||||||
|
|
@ -12,7 +12,7 @@
|
||||||
|
|
||||||
settings = {
|
settings = {
|
||||||
confirm_os_window_close = 0;
|
confirm_os_window_close = 0;
|
||||||
background_opacity = "0.25";
|
background_opacity = "0.50";
|
||||||
window_padding_width = 10;
|
window_padding_width = 10;
|
||||||
scrollback_lines = 10000;
|
scrollback_lines = 10000;
|
||||||
enable_audio_bell = false;
|
enable_audio_bell = false;
|
||||||
|
|
@ -35,5 +35,102 @@
|
||||||
"ctrl+shift+left" = "no_op";
|
"ctrl+shift+left" = "no_op";
|
||||||
"ctrl+shift+right" = "no_op";
|
"ctrl+shift+right" = "no_op";
|
||||||
};
|
};
|
||||||
|
extraConfig = ''
|
||||||
|
# vim:ft=kitty
|
||||||
|
|
||||||
|
## name: Base2Tone Suburb Dark
|
||||||
|
## author: Bram de Haan (https://github.com/atelierbram)
|
||||||
|
## license: MIT
|
||||||
|
## upstream: https://github.com/atelierbram/Base2Tone-kitty/blob/main/themes/base2tone-suburb-dark.conf
|
||||||
|
## blurb: duotone theme | warm blue - bright pink
|
||||||
|
|
||||||
|
|
||||||
|
#: The basic colors
|
||||||
|
|
||||||
|
foreground #878ba6
|
||||||
|
# background #1e202f
|
||||||
|
selection_foreground #878ba6
|
||||||
|
selection_background #292c3d
|
||||||
|
|
||||||
|
|
||||||
|
#: Cursor colors
|
||||||
|
|
||||||
|
cursor #d14781
|
||||||
|
cursor_text_color #1e202f
|
||||||
|
|
||||||
|
|
||||||
|
#: URL underline color when hovering with mouse
|
||||||
|
|
||||||
|
url_color #d2d8fe
|
||||||
|
|
||||||
|
|
||||||
|
#: kitty window border colors and terminal bell colors
|
||||||
|
|
||||||
|
active_border_color #444864
|
||||||
|
inactive_border_color #1e202f
|
||||||
|
bell_border_color #5165e6
|
||||||
|
visual_bell_color none
|
||||||
|
|
||||||
|
|
||||||
|
#: OS Window titlebar colors
|
||||||
|
|
||||||
|
wayland_titlebar_color #292c3d
|
||||||
|
macos_titlebar_color #292c3d
|
||||||
|
|
||||||
|
|
||||||
|
#: Tab bar colors
|
||||||
|
|
||||||
|
active_tab_foreground #fbf9fa
|
||||||
|
active_tab_background #1e202f
|
||||||
|
inactive_tab_foreground #b0a6aa
|
||||||
|
inactive_tab_background #292c3d
|
||||||
|
tab_bar_background #292c3d
|
||||||
|
tab_bar_margin_color none
|
||||||
|
|
||||||
|
|
||||||
|
#: Colors for marks (marked text in the terminal)
|
||||||
|
|
||||||
|
mark1_foreground #1e202f
|
||||||
|
mark1_background #6375ee
|
||||||
|
mark2_foreground #1e202f
|
||||||
|
mark2_background #8d8186
|
||||||
|
mark3_foreground #1e202f
|
||||||
|
mark3_background #e44e8c
|
||||||
|
|
||||||
|
|
||||||
|
#: The basic 16 colors
|
||||||
|
|
||||||
|
#: black
|
||||||
|
color0 #1e202f
|
||||||
|
color8 #4f5472
|
||||||
|
|
||||||
|
#: red
|
||||||
|
color1 #7586f5
|
||||||
|
color9 #fe81b5
|
||||||
|
|
||||||
|
#: green
|
||||||
|
color2 #fb6fa9
|
||||||
|
color10 #292c3d
|
||||||
|
|
||||||
|
#: yellow
|
||||||
|
color3 #ffb3d2
|
||||||
|
color11 #444864
|
||||||
|
|
||||||
|
#: blue
|
||||||
|
color4 #8696fd
|
||||||
|
color12 #5b6080
|
||||||
|
|
||||||
|
#: magenta
|
||||||
|
color5 #fb6fa9
|
||||||
|
color13 #d2d8fe
|
||||||
|
|
||||||
|
#: cyan
|
||||||
|
color6 #a0acfe
|
||||||
|
color14 #f764a1
|
||||||
|
|
||||||
|
#: white
|
||||||
|
color7 #878ba6
|
||||||
|
color15 #ebedff
|
||||||
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -11,6 +11,18 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
autocd = true;
|
autocd = true;
|
||||||
autosuggestion.enable = true;
|
autosuggestion.enable = true;
|
||||||
|
syntaxHighlighting = {
|
||||||
|
enable = true;
|
||||||
|
highlighters = [
|
||||||
|
"main"
|
||||||
|
"brackets"
|
||||||
|
"pattern"
|
||||||
|
"regexp"
|
||||||
|
"cursor"
|
||||||
|
"root"
|
||||||
|
"line"
|
||||||
|
];
|
||||||
|
};
|
||||||
enableCompletion = true;
|
enableCompletion = true;
|
||||||
# enableGlobalCompInit = true; # Should be a thing according to NixOS options but is not a thing?
|
# enableGlobalCompInit = true; # Should be a thing according to NixOS options but is not a thing?
|
||||||
|
|
||||||
|
|
@ -137,6 +149,7 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
abbreviations = {
|
abbreviations = {
|
||||||
mkdir = "mkdir -p";
|
mkdir = "mkdir -p";
|
||||||
|
mv = "mv --interactive";
|
||||||
vim = "nvim";
|
vim = "nvim";
|
||||||
v = "nvim";
|
v = "nvim";
|
||||||
vi = "nvim";
|
vi = "nvim";
|
||||||
|
|
@ -191,6 +204,7 @@
|
||||||
sxiv = "nsxiv";
|
sxiv = "nsxiv";
|
||||||
enby = "man";
|
enby = "man";
|
||||||
woman = "man";
|
woman = "man";
|
||||||
|
mkcd = "mkdir $1 && cd $1";
|
||||||
|
|
||||||
# NixOS
|
# NixOS
|
||||||
ns = "nix-shell --run zsh";
|
ns = "nix-shell --run zsh";
|
||||||
|
|
@ -202,16 +216,16 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
plugins = with pkgs; [
|
plugins = with pkgs; [
|
||||||
{
|
#{
|
||||||
name = "zsh-syntax-highlighting";
|
# name = "zsh-syntax-highlighting";
|
||||||
src = fetchFromGitHub {
|
# src = fetchFromGitHub {
|
||||||
owner = "zsh-users";
|
# owner = "zsh-users";
|
||||||
repo = "zsh-syntax-highlighting";
|
# repo = "zsh-syntax-highlighting";
|
||||||
rev = "0.6.0";
|
# rev = "0.6.0";
|
||||||
sha256 = "0zmq66dzasmr5pwribyh4kbkk23jxbpdw4rjxx0i7dx8jjp2lzl4";
|
# sha256 = "0zmq66dzasmr5pwribyh4kbkk23jxbpdw4rjxx0i7dx8jjp2lzl4";
|
||||||
};
|
# };
|
||||||
file = "zsh-syntax-highlighting.zsh";
|
# file = "zsh-syntax-highlighting.zsh";
|
||||||
}
|
#}
|
||||||
{
|
{
|
||||||
name = "zsh-autopair";
|
name = "zsh-autopair";
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
|
|
|
||||||
18
modules/services/nix-serve.nix
Normal file
18
modules/services/nix-serve.nix
Normal file
|
|
@ -0,0 +1,18 @@
|
||||||
|
{ config, ... }:
|
||||||
|
{
|
||||||
|
services = {
|
||||||
|
nix-serve = {
|
||||||
|
enable = true;
|
||||||
|
secretKeyFile = "/var/secrets/cache-private-key.pem";
|
||||||
|
};
|
||||||
|
|
||||||
|
nginx.virtualHosts."violet.booping.local" = {
|
||||||
|
forceSSL = false;
|
||||||
|
# sslCertificate = "/var/lib/acme/liv.town/cert.pem";
|
||||||
|
# sslCertificateKey = "/var/lib/acme/liv.town/key.pem";
|
||||||
|
locations."/" = {
|
||||||
|
proxyPass = "http://${config.services.nix-serve.bindAddress}:${toString config.services.nix-serve.port}";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
55
modules/services/remote-build.nix
Normal file
55
modules/services/remote-build.nix
Normal file
|
|
@ -0,0 +1,55 @@
|
||||||
|
{
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
username,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
{
|
||||||
|
users.users.remotebuild = {
|
||||||
|
isNormalUser = true;
|
||||||
|
createHome = false;
|
||||||
|
group = "remotebuild";
|
||||||
|
openssh.authorizedKeys.keys = config.users.users.${username}.openssh.authorizedKeys.keys ++ [
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINKI2KQn97mykFLIaMUWMftA1txJec9qW56hAMj5/MhE liv@dandelion
|
||||||
|
"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
users.groups.remotebuild = { };
|
||||||
|
|
||||||
|
nix = {
|
||||||
|
nrBuildUsers = 64;
|
||||||
|
settings = {
|
||||||
|
trusted-users = [ "remotebuild" ];
|
||||||
|
|
||||||
|
min-free = 10 * 1024 * 1024;
|
||||||
|
max-free = 200 * 1024 * 1024;
|
||||||
|
|
||||||
|
max-jobs = "auto";
|
||||||
|
cores = 0;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.services.nix-daemon.serviceConfig = {
|
||||||
|
MemoryAccounting = true;
|
||||||
|
MemoryMax = "90%";
|
||||||
|
OOMScoreAdjust = 500;
|
||||||
|
};
|
||||||
|
|
||||||
|
# add to clients:
|
||||||
|
# nix.distributedBuilds = true;
|
||||||
|
# nix.settings.builders-use-substitutes = true;
|
||||||
|
# nix.buildMachines = [
|
||||||
|
# {
|
||||||
|
# hostName = "violet";
|
||||||
|
# sshUser = "remotebuild";
|
||||||
|
# sshKey = "/home/liv/.ssh/id_ed25519"; # Make sure to give a key that works for this user.
|
||||||
|
# system = pkgs.stdenv.hostPlatform.system;
|
||||||
|
# supportedFeatures = [
|
||||||
|
# "nixos-test"
|
||||||
|
# "big-parallel"
|
||||||
|
# "kvm"
|
||||||
|
# ];
|
||||||
|
# }
|
||||||
|
# ];
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue