-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcronjob.sh
18 lines (15 loc) · 1.17 KB
/
cronjob.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/usr/bin/env bash
#
# nicsdru-logging/scripts/example.cronjob.sh
#
# Calls shiplog.sh to ship latest log entries from various logs
# to logz.io.
# /bin/bash /app/nicsdru-logging/scripts/shiplog.sh "[LOG_NAME]" "[LOG_PATH]" "[LOG_DATE_PATTERN]" "[LOG_TYPE]"
# Ship /var/log/access.log generated by nginx.
/bin/bash /app/nicsdru-logging/scripts/shiplog.sh "access" "/var/log/access.log" "$(date +%d/%b/%Y:)" "nginx_access"
# Uncomment following line to ship drupal.log generated by D9 filelog module.
/bin/bash /app/nicsdru-logging/scripts/shiplog.sh "drupal-nisra" "/app/log/nisra/drupal.log" "$(date +'%a, %d/%m/%Y -')" "drupal"
/bin/bash /app/nicsdru-logging/scripts/shiplog.sh "drupal-etini" "/app/log/etini/drupal.log" "$(date +'%a, %d/%m/%Y -')" "drupal"
/bin/bash /app/nicsdru-logging/scripts/shiplog.sh "drupal-afbini" "/app/log/afbini/drupal.log" "$(date +'%a, %d/%m/%Y -')" "drupal"
/bin/bash /app/nicsdru-logging/scripts/shiplog.sh "drupal-hseni" "/app/log/hseni/drupal.log" "$(date +'%a, %d/%m/%Y -')" "drupal"
/bin/bash /app/nicsdru-logging/scripts/shiplog.sh "drupal-northsouthministerialcouncil" "/app/log/northsouthministerialcouncil/drupal.log" "$(date +'%a, %d/%m/%Y -')" "drupal"