Files

27 lines
924 B
ObjectPascal
Raw Permalink Normal View History

2026-09-22 11:54:36 +02:00
## confdroid_clamav::main::config.pp
# Module name: confdroid_clamav
# Author: 12ww1160 (12ww1160@confdroid.com)
2019-10-28 17:40:12 +01:00
# @summary Class manages all aspects of configuring the module logic for
2026-09-22 11:54:36 +02:00
# confdroid_clamav.
2019-10-28 17:40:12 +01:00
##############################################################################
2026-09-22 11:54:36 +02:00
class confdroid_clamav::main::config (
2019-10-28 17:40:12 +01:00
2026-09-22 11:54:36 +02:00
) inherits confdroid_clamav::params {
include confdroid_clamav::main::service
2025-06-08 14:26:09 +02:00
# Ensure the SELinux boolean antivirus_can_scan_system is enabled if disabled
exec { 'enable_antivirus_can_scan_system':
command => '/usr/sbin/setsebool -P antivirus_can_scan_system 1',
unless => '/usr/sbin/getsebool antivirus_can_scan_system | grep --quiet "on"',
path => ['/usr/sbin', '/bin'],
}
2025-06-08 15:05:28 +02:00
# create a cron job to run a daily scan
cron { 'clamscan':
2025-06-08 15:33:03 +02:00
command => $cv_shell_script,
user => $cv_cron_user,
hour => $cv_cron_hour,
minute => $cv_cron_minute,
2025-06-08 15:05:28 +02:00
}
2019-10-28 17:40:12 +01:00
}