Skip to content

Commit

Permalink
Missing grep filter
Browse files Browse the repository at this point in the history
  • Loading branch information
catttam committed Oct 4, 2024
1 parent da6c659 commit 2144dcf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions extract_goaccess_metrics.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ LOG_FORMAT='%^ %^ %^ %^ [%^] %d - %t | %s | %Tms | %h | %m %~ %U | %u'

addLog(){
ingress_logfile=$1
cat $ingress_logfile | grep -a '/job\|/run' | tee -a $HISTORY_LOGS >/dev/null
cat $ingress_logfile | grep GIN-EXECUTIONS-LOGGER | grep -a '/job\|/run' | tee -a $HISTORY_LOGS >/dev/null
}

metrics(){
Expand Down Expand Up @@ -76,7 +76,7 @@ do
if [[ $logfile == *".log"* ]]; then
if [[ $logfile == *".log" ]]; then
aws s3 cp $logfile s3://metrics.oscar.grycap.net/"${CLUSTER_ID}"/ingresslogs/
cat $logfile | grep -a '/job\|/run' | tee -a $LATEST_LOGS >/dev/null
cat $logfile | grep GIN-EXECUTIONS-LOGGER | grep -a '/job\|/run' | tee -a $LATEST_LOGS >/dev/null
metrics $LATEST_LOGS
else
addLog $logfile
Expand Down

0 comments on commit 2144dcf

Please sign in to comment.