Browse Source

Schedule daily STIG tests

Bob Mottram 8 years ago
parent
commit
4ed6e4ff7f
2 changed files with 10 additions and 0 deletions
  1. 7
    0
      src/freedombone-utils-cron
  2. 3
    0
      src/freedombone-utils-setup

+ 7
- 0
src/freedombone-utils-cron View File

@@ -77,4 +77,11 @@ function randomize_cron {
77 77
     mark_completed $FUNCNAME
78 78
 }
79 79
 
80
+function schedule_stig_tests {
81
+    echo '#!/bin/bash' > /etc/cron.daily/stig_tests
82
+    echo "pkill ${PROJECT_NAME}-tests" >> /etc/cron.daily/stig_tests
83
+    echo '${PROJECT_NAME}-tests --stig yes' >> /etc/cron.daily/stig_tests
84
+    chmod +x /etc/cron.daily/stig_tests
85
+}
86
+
80 87
 # NOTE: deliberately there is no "exit 0"

+ 3
- 0
src/freedombone-utils-setup View File

@@ -751,6 +751,9 @@ function setup_utils {
751 751
 
752 752
     function_check limit_user_logins
753 753
     limit_user_logins
754
+
755
+    function_check schedule_stig_tests
756
+    schedule_stig_tests
754 757
 }
755 758
 
756 759
 function setup_email {