merge-requests/100/head
Pyjacpp 2026-11-11 12:43:25 +01:00
parent 9aa3a3122e
commit 24cc6783de
No known key found for this signature in database
GPG Key ID: ED479A5A26930939
4 changed files with 6 additions and 4 deletions

View File

@ -14,7 +14,6 @@ in
{ {
imports = [ imports = [
./age.nix ./age.nix
./anubis.nix
./grub.nix ./grub.nix
./home.nix ./home.nix
./locale.nix ./locale.nix

View File

@ -72,7 +72,7 @@ in
let let
redCfg = config.services.redis.servers.anubis; redCfg = config.services.redis.servers.anubis;
in in
{ mkIf cfg.useRedis {
backend = "valkey"; backend = "valkey";
parameters.url = "redis://${redCfg.bind}:${toString redCfg.port}/0"; parameters.url = "redis://${redCfg.bind}:${toString redCfg.port}/0";
}; };
@ -99,7 +99,8 @@ in
} }
] ]
++ conf.bots; ++ conf.bots;
# Inclus via l’import de default-config.yaml. # Inclus via l’import de default-config.yaml. Et on préfére mettre le
# whitelist Crans avant.
useDefaultBotRules = false; useDefaultBotRules = false;
}; };
settings = { settings = {
@ -122,7 +123,7 @@ in
# Meilleure licence que Redis # Meilleure licence que Redis
package = pkgs.valkey; package = pkgs.valkey;
servers.anubis = { servers.anubis = {
enable = true; enable = cfg.useRedis;
bind = "127.0.0.1"; bind = "127.0.0.1";
port = 6379; port = 6379;
databases = 1; databases = 1;

View File

@ -3,6 +3,7 @@
{ {
imports = [ imports = [
./acme.nix ./acme.nix
./anubis.nix
./nginx.nix ./nginx.nix
./restic.nix ./restic.nix
./reverseproxy.nix ./reverseproxy.nix

View File

@ -154,6 +154,7 @@ in
# On active Anubis # On active Anubis
crans.anubis = { crans.anubis = {
enable = true; enable = true;
useRedis = true;
instances = lib.mapAttrs (vhostName: vhostConfig: { instances = lib.mapAttrs (vhostName: vhostConfig: {
hostname = mkHostName vhostName mainTld; hostname = mkHostName vhostName mainTld;
bind = "/run/anubis/anubis-${vhostName}/socket.sock"; bind = "/run/anubis/anubis-${vhostName}/socket.sock";