Archived
modularized traefik log rotatation config
This commit is contained in:
@@ -25,6 +25,7 @@ in
|
|||||||
../../modules/docker/enable-service.nix
|
../../modules/docker/enable-service.nix
|
||||||
# ../../modules/nix/tailscale-service.nix
|
# ../../modules/nix/tailscale-service.nix
|
||||||
../../modules/tailscale/enable-service.nix
|
../../modules/tailscale/enable-service.nix
|
||||||
|
../../modules/rotate-traefik-logs.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
||||||
@@ -39,22 +40,22 @@ boot.zfs.forceImportRoot = false;
|
|||||||
nfs-utils
|
nfs-utils
|
||||||
];
|
];
|
||||||
|
|
||||||
services.logrotate = {
|
# services.logrotate = {
|
||||||
enable = true;
|
# enable = true;
|
||||||
|
|
||||||
settings = {
|
# settings = {
|
||||||
"/mnt/docker-volumes/traefik-data/logs/*.log" = {
|
# "/mnt/docker-volumes/traefik-data/logs/*.log" = {
|
||||||
daily = true;
|
# daily = true;
|
||||||
size = "100M";
|
# size = "100M";
|
||||||
rotate = 20;
|
# rotate = 20;
|
||||||
compress = true;
|
# compress = true;
|
||||||
missingok = true;
|
# missingok = true;
|
||||||
notifempty = true;
|
# notifempty = true;
|
||||||
copytruncate = true;
|
# copytruncate = true;
|
||||||
};
|
# };
|
||||||
|
|
||||||
};
|
# };
|
||||||
};
|
# };
|
||||||
|
|
||||||
|
|
||||||
boot.supportedFilesystems = [ "nfs" ];
|
boot.supportedFilesystems = [ "nfs" ];
|
||||||
|
|||||||
@@ -0,0 +1,20 @@
|
|||||||
|
{ ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
services.logrotate = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
settings = {
|
||||||
|
"/mnt/docker-volumes/traefik-data/logs/*.log" = {
|
||||||
|
daily = true;
|
||||||
|
size = "100M";
|
||||||
|
rotate = 20;
|
||||||
|
compress = true;
|
||||||
|
missingok = true;
|
||||||
|
notifempty = true;
|
||||||
|
copytruncate = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user