From 06ffdeb5b93f1701ce9de23b34d22a1454020cef Mon Sep 17 00:00:00 2001 From: catttam Date: Mon, 21 Oct 2024 12:30:02 +0200 Subject: [PATCH] Fixed var error --- extract_logs_metrics.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extract_logs_metrics.sh b/extract_logs_metrics.sh index d2cb697..b6bb058 100755 --- a/extract_logs_metrics.sh +++ b/extract_logs_metrics.sh @@ -67,8 +67,8 @@ do # Remove total path relative_log_path=$(echo $log_path | sed 's/\/var\/log\/clusterlogs\///') # Upload current logs to s3 - aws s3 cp --recursive $log_path s3://metrics.oscar.grycap.net/"${CLUSTER_ID}"/ingresslogs/"${log_relative_path}" - for logfile in "$LOCAL_LOGS_DIR/$log_relative_path/oscar/"*; + aws s3 cp --recursive $log_path s3://metrics.oscar.grycap.net/"${CLUSTER_ID}"/ingresslogs/"${relative_log_path}" + for logfile in "$LOCAL_LOGS_DIR/$relative_log_path/oscar/"*; do if [[ $logfile == *".gz" ]]; then # unzip all log files