<PackageReference Include="Serilog.Sinks.RollingFile" Version="3.2.0" />

Serilog.RollingFileLoggerConfigurationExtensions

Extends LoggerSinkConfiguration with rolling file configuration methods.
public static LoggerConfiguration RollingFile(this LoggerSinkConfiguration sinkConfiguration, string pathFormat, LogEventLevel restrictedToMinimumLevel = 0, string outputTemplate = "{Timestamp:yyyy-MM-dd HH:mm:ss.fff zzz} [{Level}] {Message}{NewLine}{Exception}", IFormatProvider formatProvider = null, long? fileSizeLimitBytes = 1073741824, int? retainedFileCountLimit = 31, LoggingLevelSwitch levelSwitch = null, bool buffered = false, bool shared = false, TimeSpan? flushToDiskInterval = default)

Write log events to a series of files. Each file will be named according to the date of the first log entry written to it. Only simple date-based rolling is currently supported.

public static LoggerConfiguration RollingFile(this LoggerSinkConfiguration sinkConfiguration, ITextFormatter formatter, string pathFormat, LogEventLevel restrictedToMinimumLevel = 0, long? fileSizeLimitBytes = 1073741824, int? retainedFileCountLimit = 31, LoggingLevelSwitch levelSwitch = null, bool buffered = false, bool shared = false, TimeSpan? flushToDiskInterval = default)

Write log events to a series of files. Each file will be named according to the date of the first log entry written to it. Only simple date-based rolling is currently supported.