# Flatcar: This is a modified version of the default config that came
# with Gentoo Linux.

#
# Default logrotate(8) configuration file for Gentoo Linux.
# See "man logrotate" for details.

# rotate log files weekly.
#weekly
#daily

# keep 4 weeks worth of backlogs.
#rotate 4

# Flatcar: keep only the most recent old log.
rotate 1

# create new (empty) log files after rotating old ones.
create

# use date as a suffix of the rotated file.
dateext

# compress rotated log files.
compress

# Flatcar: If a file to rotate is missing, don't log an error.
missingok
notifempty
nomail
noolddir

# packages can drop log rotation information into this directory.
include /etc/logrotate.d

# no packages own wtmp and btmp -- we'll rotate them here.
# must match creation rules in /usr/lib/tmpfiles.d/var.conf
/var/log/wtmp {
    create 0664 root utmp
    size 1M
}
/var/log/btmp {
    create 0600 root utmp
    size 1M
}

# system-specific logs may also be configured here.
