nix fmt; justfile adjustments

This commit is contained in:
xqtc161 2024-07-01 20:45:31 +02:00
parent 692e3f5ccb
commit b9e4385f0c
9 changed files with 62 additions and 43 deletions

View file

@ -19,15 +19,15 @@ with inputs; {
sponsorblock sponsorblock
# dearrow # dearrow
pronoundb pronoundb
tabcenter-reborn tabcenter-reborn
firefox-color firefox-color
unpaywall unpaywall
bitwarden bitwarden
sidebery sidebery
leechblock-ng leechblock-ng
darkreader darkreader
stylus stylus
shinigami-eyes shinigami-eyes
violentmonkey violentmonkey
vimium-c vimium-c
noscript noscript

View file

@ -65,7 +65,7 @@ in {
pkgs.ghc pkgs.ghc
pkgs.rizin pkgs.rizin
(pkgs.cutter.withPlugins (ps: with ps; [ jsdec rz-ghidra sigdb ])) (pkgs.cutter.withPlugins (ps: with ps; [jsdec rz-ghidra sigdb]))
pkgs.imhex pkgs.imhex
pkgs.ghidra pkgs.ghidra

View file

@ -1,5 +1,9 @@
{config, lib, pkgs, ...}:
{ {
config,
lib,
pkgs,
...
}: {
programs.yazi = { programs.yazi = {
enable = true; enable = true;
enableNushellIntegration = true; enableNushellIntegration = true;

View file

@ -1,5 +1,9 @@
{ config, lib, pkgs, ... }: { {
config,
lib,
pkgs,
...
}: {
# #
# BACKUP # BACKUP
# Check via nix-shell -p borgbackup --run "borg info --rsh 'ssh -p 23 -i /home/moe/.ssh/storagebox_nextcloud_data' u409248-sub1@u409248-sub1.your-storagebox.de:nextcloud_data_backups" # Check via nix-shell -p borgbackup --run "borg info --rsh 'ssh -p 23 -i /home/moe/.ssh/storagebox_nextcloud_data' u409248-sub1@u409248-sub1.your-storagebox.de:nextcloud_data_backups"
@ -34,14 +38,14 @@
nextcloud_data = { nextcloud_data = {
user = "nextcloud"; user = "nextcloud";
group = "nextcloud"; group = "nextcloud";
paths = [ "${config.services.nextcloud.datadir}" ]; paths = ["${config.services.nextcloud.datadir}"];
preHook = '' preHook = ''
${config.services.nextcloud.occ}/bin/nextcloud-occ maintenance:mode --on ${config.services.nextcloud.occ}/bin/nextcloud-occ maintenance:mode --on
''; '';
postHook = '' postHook = ''
${config.services.nextcloud.occ}/bin/nextcloud-occ maintenance:mode --off ${config.services.nextcloud.occ}/bin/nextcloud-occ maintenance:mode --off
''; '';
repo = "u409248-sub1@u409248-sub1.your-storagebox.de:nextcloud_data_backups"; repo = "u409248-sub1@u409248-sub1.your-storagebox.de:nextcloud_data_backups";
encryption = { encryption = {
mode = "repokey-blake2"; mode = "repokey-blake2";
passCommand = "cat ${config.age.secrets.backup_nextcloud_data_passphrase.path}"; passCommand = "cat ${config.age.secrets.backup_nextcloud_data_passphrase.path}";
@ -64,7 +68,7 @@
postHook = '' postHook = ''
${config.services.nextcloud.occ}/bin/nextcloud-occ maintenance:mode --off ${config.services.nextcloud.occ}/bin/nextcloud-occ maintenance:mode --off
''; '';
repo = "u409248-sub2@u409248-sub2.your-storagebox.de:nextcloud_database_backups"; repo = "u409248-sub2@u409248-sub2.your-storagebox.de:nextcloud_database_backups";
encryption = { encryption = {
mode = "repokey-blake2"; mode = "repokey-blake2";
passCommand = "cat ${config.age.secrets.backup_nextcloud_database_passphrase.path}"; passCommand = "cat ${config.age.secrets.backup_nextcloud_database_passphrase.path}";
@ -78,12 +82,12 @@
}; };
systemd.services."borgbackup-job-nextcloud_data" = { systemd.services."borgbackup-job-nextcloud_data" = {
onFailure = [ "notify-email@%i.service" ]; onFailure = ["notify-email@%i.service"];
onSuccess = [ "notify-email@%i.service" ]; onSuccess = ["notify-email@%i.service"];
}; };
systemd.services."borgbackup-job-nextcloud_database" = { systemd.services."borgbackup-job-nextcloud_database" = {
onFailure = [ "notify-email@%i.service" ]; onFailure = ["notify-email@%i.service"];
onSuccess = [ "notify-email@%i.service" ]; onSuccess = ["notify-email@%i.service"];
}; };
} }

View file

@ -95,29 +95,29 @@ with lib; {
''; '';
}; };
"jellyfin.heroin.trade" = { "jellyfin.heroin.trade" = {
extraConfig = '' extraConfig = ''
reverse_proxy http://127.0.0.1:8096 reverse_proxy http://127.0.0.1:8096
''; '';
}; };
"calibre.heroin.trade" = { "calibre.heroin.trade" = {
extraConfig = '' extraConfig = ''
reverse_proxy http://localhost:3000 reverse_proxy http://localhost:3000
''; '';
}; };
"grafana.heroin.trade" = { "grafana.heroin.trade" = {
extraConfig = '' extraConfig = ''
reverse_proxy http://127.0.0.1:2342 reverse_proxy http://127.0.0.1:2342
''; '';
}; };
"uptime.heroin.trade" = { "uptime.heroin.trade" = {
extraConfig = '' extraConfig = ''
reverse_proxy http://127.0.0.1:3001 reverse_proxy http://127.0.0.1:3001
''; '';
}; };
"paperless.heroin.trade" = { "paperless.heroin.trade" = {
extraConfig = '' extraConfig = ''
reverse_proxy http://127.0.0.1:28981 reverse_proxy http://127.0.0.1:28981
''; '';
}; };
}; };
}; };
@ -161,10 +161,10 @@ with lib; {
]; ];
}; };
users.users.root.openssh.authorizedKeys.keys = [ users.users.root.openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJTLJqIVwnqFO64rnc66d234TFOdFXpDS9fJUA4/f4in xqtc@alastor" "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJTLJqIVwnqFO64rnc66d234TFOdFXpDS9fJUA4/f4in xqtc@alastor"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIN7UkcmSVo+SeB5Obevz3mf3UHruYxn0UHUzoOs2gDBy xqtc@asmodeus" "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIN7UkcmSVo+SeB5Obevz3mf3UHruYxn0UHUzoOs2gDBy xqtc@asmodeus"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPf3w5bHAssHthg9SPXVpG4w9v8m16X/0J3bjg08P6EA xqtc@seraphim" "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPf3w5bHAssHthg9SPXVpG4w9v8m16X/0J3bjg08P6EA xqtc@seraphim"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJYa+LoHGGvu12iBufUcr3GD8tsq4LuJdwLjaDkTr0SL xqtc@lilith" "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJYa+LoHGGvu12iBufUcr3GD8tsq4LuJdwLjaDkTr0SL xqtc@lilith"
]; ];
programs.bash.blesh.enable = true; programs.bash.blesh.enable = true;

View file

@ -15,7 +15,7 @@
REQUIRE_SIGNIN_VIEW = true; REQUIRE_SIGNIN_VIEW = true;
}; };
DEFAULT = { DEFAULT = {
APP_NAME = "Git so good it could be heroin"; APP_NAME = "Git so good it could be heroin";
}; };
}; };
}; };

View file

@ -1,7 +1,11 @@
{config, lib, inputs, ...}:
{ {
services.paperless = { config,
enable = true; lib,
passwordFile = "/etc/paperless_sc"; inputs,
}; ...
}: {
services.paperless = {
enable = true;
passwordFile = "/etc/paperless_sc";
};
} }

View file

@ -126,7 +126,7 @@
# Define a user account. Don't forget to set a password with passwd. # Define a user account. Don't forget to set a password with passwd.
users.users.xqtc = { users.users.xqtc = {
isNormalUser = true; isNormalUser = true;
extraGroups = ["wheel" "docker" "libvirtd" "adbusers" ]; # Enable sudo for the user. extraGroups = ["wheel" "docker" "libvirtd" "adbusers"]; # Enable sudo for the user.
packages = with pkgs; [nushell clamtk]; packages = with pkgs; [nushell clamtk];
shell = pkgs.nushell; shell = pkgs.nushell;
}; };

View file

@ -11,9 +11,16 @@ rebuild:
nh os switch . -- -vv --impure -j 4; nh os switch . -- -vv --impure -j 4;
exit exit
fi fi
nh os switch . -- -vv --impure -j 4; nh os switch . -- -vv;
beleth: beleth:
nixos-rebuild switch --flake '.#beleth' --build-host {{beleth-host}} --target-host {{beleth-host}} #!/usr/bin/env bash
ssh {{beleth-user-host}} "cd; cd nixos-config; git pull; cd; sh build_website.sh" arch=$(nix-instantiate --eval -E 'builtins.currentSystem')
arch_sanitized=$(echo $arch | sed 's/^"//;s/"$//')
if [ $arch_sanitized == "x86_64-linux" ]; then
nixos-rebuild switch --flake '.#beleth' --build-host {{beleth-host}} --target-host {{beleth-host}};
ssh {{beleth-user-host}} "cd; cd nixos-config; git pull; cd; sh build_website.sh";
exit
fi
@echo "Host arch needs to be 'x86_64-linux'! Aborting...";