/etc/logrotate.conf (1)

From RaySoft
# ------------------------------------------------------------------------------
# logrotate.conf
# ==============
#
# Project   Gentoo 4 Shuttle DS57Ux
# Scope     Gentoo
# Copyright (C) 2022 by RaySoft, Zurich, Switzerland
# License   GNU General Public License (GPL) 2.0
#           https://www.gnu.org/licenses/gpl2.txt
#
# ------------------------------------------------------------------------------

# Log files are rotated if the current weekday is less than the weekday of the
# last rotation or if more than a week has passed since the last rotation.
# weekly

# Log files are rotated every day.
daily

# Log files are rotated count times before being removed or mailed to the
# address specified in a mail directive. If count is 0, old versions are removed
# rather than rotated.
rotate 5

# Immediately after rotation (before the postrotate script is run) the log file
# is created (with the same name as the log file just rotated).
create

# Archive old versions of log files adding a daily extension like YYYYMMDD
# instead of simply adding a number. The extension may be configured using the
# dateformat option.
dateext

# Old versions of log files are compressed with gzip by default.
compress

# Do not rotate the log if it is empty (this overrides the ifempty option).
notifempty

# Don't mail old log files to any address.
nomail

# Logs are rotated in the same directory the log normally resides in (this
# overrides the olddir option).
noolddir

# Reads the file given as an argument as if it was included inline where the
# include directive appears. If a directory is given, most of the files in that
# directory are read in alphabetic order before processing of the including file
# continues.
include /etc/logrotate.d

# ------------------------------------------------------------------------------

'/var/log/wtmp' {
    monthly
    create 0664 root utmp
    minsize 1M
    rotate 1
}

'/var/log/btmp' {
    missingok
    monthly
    create 0600 root utmp
    rotate 1
}

# ------------------------------------------------------------------------------