Merge branch 'b12f' of git.pub.solar:pub-solar/os into b12f
This commit is contained in:
commit
d043855b44
|
@ -29,6 +29,7 @@ in
|
|||
wayvnc
|
||||
drone-docker-runner
|
||||
stdenv.cc.cc.lib
|
||||
pkgs.hplip
|
||||
];
|
||||
|
||||
age.secrets."vnc-key.pem" = {
|
||||
|
|
|
@ -22,6 +22,7 @@ in
|
|||
enable = true;
|
||||
port = 34197; # The default, but make it explicit
|
||||
lan = true;
|
||||
game-password = "pls-dont-grief";
|
||||
admins = [
|
||||
"doubtwriter"
|
||||
"kattykat"
|
||||
|
@ -30,9 +31,13 @@ in
|
|||
autosave-interval = 3;
|
||||
game-name = "Babes plays v2";
|
||||
requireUserVerification = false;
|
||||
bind = "::";
|
||||
mods = [
|
||||
far-reach
|
||||
];
|
||||
};
|
||||
|
||||
networking.firewall.allowedUDPPorts = [ 34197 ];
|
||||
networking.firewall.allowedTCPPorts = [ 34197 ];
|
||||
};
|
||||
}
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
let
|
||||
shutdownWaitMinutes = 15;
|
||||
shutdownScript = pkgs.writeScript "shutdown" ''
|
||||
shutdownScript = pkgs.writeShellScriptBin "shutdown-wait" ''
|
||||
STATUS_FILES="/media/internal/backups-pub-solar/status"
|
||||
|
||||
running=""
|
||||
|
@ -37,7 +37,7 @@ in
|
|||
systemd.services."shutdown-after-backup" = {
|
||||
enable = true;
|
||||
serviceConfig = {
|
||||
ExecStart = "${pkgs.bash}/bin/bash ${shutdownScript}";
|
||||
ExecStart = "${shutdownScript}/bin/shutdown-wait";
|
||||
Type = "oneshot";
|
||||
};
|
||||
};
|
||||
|
@ -45,7 +45,7 @@ in
|
|||
systemd.timers."shutdown-after-backup" = {
|
||||
enable = true;
|
||||
timerConfig = {
|
||||
OnCalendar = "3..9:*";
|
||||
OnCalendar = "3..9:* Etc/UTC";
|
||||
};
|
||||
wantedBy = [ "timers.target" ];
|
||||
partOf = [ "shutdown-after-backup.service" ];
|
||||
|
|
|
@ -43,12 +43,18 @@ in
|
|||
nix.binaryCachePublicKeys = cfg.publicKeys;
|
||||
|
||||
# These entries get added to /etc/hosts
|
||||
networking.hosts = {
|
||||
"127.0.0.1" = [ ]
|
||||
++ lib.optionals cfg.enableCaddy [ "caddy.local" ]
|
||||
++ lib.optionals config.pub-solar.printing.enable [ "cups.local" ]
|
||||
++ lib.optionals cfg.enableHelp [ "help.local" ];
|
||||
};
|
||||
networking.hosts =
|
||||
let
|
||||
hostnames = [ ]
|
||||
++ lib.optionals cfg.enableCaddy [ "caddy.local" ]
|
||||
++ lib.optionals config.pub-solar.printing.enable [ "cups.local" ]
|
||||
++ lib.optionals config.pub-solar.paperless.enable [ "paperless.local" ]
|
||||
++ lib.optionals cfg.enableHelp [ "help.local" ];
|
||||
in
|
||||
{
|
||||
"127.0.0.1" = hostnames;
|
||||
"::1" = hostnames;
|
||||
};
|
||||
|
||||
# Caddy reverse proxy for local services like cups
|
||||
services.caddy = {
|
||||
|
@ -67,6 +73,15 @@ in
|
|||
}
|
||||
'')
|
||||
|
||||
(lib.optionalString
|
||||
config.pub-solar.paperless.enable
|
||||
''
|
||||
paperless.local:80 {
|
||||
request_header Host localhost:28981
|
||||
reverse_proxy localhost:28981
|
||||
}
|
||||
'')
|
||||
|
||||
(lib.optionalString
|
||||
cfg.enableHelp
|
||||
''
|
||||
|
|
|
@ -23,15 +23,15 @@ in
|
|||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
services.paperless-ng = {
|
||||
services.paperless = {
|
||||
enable = true;
|
||||
user = psCfg.user.name;
|
||||
consumptionDir = cfg.consumptionDir;
|
||||
extraConfig = {
|
||||
PAPERLESS_OCR_LANGUAGE = cfg.ocrLanguage;
|
||||
PAPERLESS_ADMIN_USER = psCfg.user.name;
|
||||
PAPERLESS_AUTO_LOGIN_USERNAME = psCfg.user.name;
|
||||
};
|
||||
};
|
||||
environment.systemPackages = [
|
||||
pkgs.hplip
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
|
@ -30,7 +30,10 @@ in
|
|||
];
|
||||
};
|
||||
|
||||
paperless.enable = true;
|
||||
paperless = {
|
||||
enable = false;
|
||||
ocrLanguage = "nld+deu";
|
||||
};
|
||||
arduino.enable = true;
|
||||
email.enable = true;
|
||||
uhk.enable = true;
|
||||
|
|
|
@ -11,6 +11,7 @@ in
|
|||
|
||||
home-manager = pkgs.lib.setAttrByPath [ "users" psCfg.user.name ] {
|
||||
home.packages = with pkgs; [
|
||||
inkscape
|
||||
nix-output-monitor
|
||||
tigervnc
|
||||
dogecoin
|
||||
|
|
Loading…
Reference in a new issue