I’ve properly enabled admin_audit app and configured both logfile and logfile_audit to have sepparated app logs (just for errors) and audit logs (for user, files events)
'loglevel' => 3,
'log_type' => 'file',
'logfile' => '/var/www/nextcloud/data/nextcloud.log',
'log_type_audit' => 'file',
'logfile_audit' => '/var/www/nextcloud/data/audit.log',
'log.condition' => [
'apps' => ['admin_audit'],
],
I’m just a bit annoyed about the huge amount of events that are recorded by audit log (for example, every preview, new folder). As I have the activity app enabled, is there any config parameter to filter the events that can be recorded? For example, just user login/logouts.
— EDIT POST-SOLUTION —
Despite I’ve marked as solution the post that exactly matches the topic of the question, perhaps you should review the alterative parsing the logs with jq instead of modifying the app source code. Anyway thanks to @ernolf for his kindly help.