Skip to content

Commit

Permalink
Update to remote logging functions
Browse files Browse the repository at this point in the history
  • Loading branch information
brian committed Apr 30, 2018
1 parent a2300a9 commit fd241ea
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
9 changes: 6 additions & 3 deletions minerchk.sh
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ log="${logdir}/miner.$(date +%y%m%d-%H%M).log"
log1="${logdir}/coinhive.$(date +%y%m%d-%H%M).log" log1="${logdir}/coinhive.$(date +%y%m%d-%H%M).log"
log2=/tmp/minerchk.report log2=/tmp/minerchk.report


#remote logging via sendmail
remotelog=$(cat /usr/local/minerchk/remotelog)

#create formatting #create formatting
div(){ div(){
for ((i=0;i<$1;i++)); do printf '='; done; for ((i=0;i<$1;i++)); do printf '='; done;
Expand Down Expand Up @@ -63,7 +66,7 @@ clear
echo echo
echo echo
header $@ header $@
echo "-- Miner Check beta v1.34 --" echo " -- Miner Check beta v1.35 --"
header $@ header $@
echo "Enter 1 to run quick miner checks on server (Active mining on server and in /tmp)" echo "Enter 1 to run quick miner checks on server (Active mining on server and in /tmp)"
echo echo
Expand Down Expand Up @@ -243,8 +246,8 @@ case "$answer" in
cat $log >> $log2 cat $log >> $log2
echo "========================== " >> $log2 echo "========================== " >> $log2
cat $log1 >> $log2 cat $log1 >> $log2
cat $log2 | sendmail miner@laskowski-tech.com cat $log2 | sendmail $remotelog
echo "Reports sents, have any other information you would like to report? Send to miner@laskowski-tech.com";; echo "Reports sents, have any other information you would like to report? Send to $remotelog";;




7) rm /tmp/minerchk.report 7) rm /tmp/minerchk.report
Expand Down
1 change: 1 addition & 0 deletions remotelog
Original file line number Original file line Diff line number Diff line change
@@ -0,0 +1 @@
miner@laskowski-tech.com

0 comments on commit fd241ea

Please sign in to comment.