From f9fee1f17fcc0be3884860fc57154c1e80968c26 Mon Sep 17 00:00:00 2001 From: Bartosz Bezak Date: Wed, 8 Mar 2023 11:28:54 +0100 Subject: [PATCH] CI: get repo directories from nodes for troubleshooting Change-Id: I0f7a3dcb021f726693725f070d9a2ff80d84fe0e --- roles/kayobe-diagnostics/files/get_logs.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/roles/kayobe-diagnostics/files/get_logs.sh b/roles/kayobe-diagnostics/files/get_logs.sh index 21846e640..bef4eb9e2 100644 --- a/roles/kayobe-diagnostics/files/get_logs.sh +++ b/roles/kayobe-diagnostics/files/get_logs.sh @@ -53,6 +53,14 @@ copy_logs() { cp -r /etc/NetworkManager/system-connections/ ${LOG_DIR}/system_logs/ fi + if [[ -d /etc/yum.repos.d/ ]]; then + cp -r /etc/yum.repos.d/ ${LOG_DIR}/system_logs/ + fi + + if [[ -d /etc/apt/sources.list.d/ ]]; then + cp -r /etc/apt/sources.list.d/ ${LOG_DIR}/system_logs/ + fi + df -h > ${LOG_DIR}/system_logs/df.txt # Gather disk usage statistics for files and directories larger than 1MB du -d 5 -hx / | sort -hr | grep '^[0-9\.]*[MGT]' > ${LOG_DIR}/system_logs/du.txt