Skip to content

Commit

Permalink
refactor: rename func
Browse files Browse the repository at this point in the history
  • Loading branch information
wafuwafu13 committed Feb 16, 2024
1 parent 191522f commit 0c21f2b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions log-collector-script/linux/eks-log-collector.sh
Original file line number Diff line number Diff line change
Expand Up @@ -426,7 +426,7 @@ get_docker_logs() {
get_k8s_info() {
try "collect kubelet information"

search_kubeconfig() {
find_kubeconfig() {
if [[ -n "${KUBECONFIG:-}" ]]; then
echo "${KUBECONFIG}"
elif [[ -f /etc/eksctl/kubeconfig.yaml ]]; then
Expand All @@ -440,7 +440,7 @@ get_k8s_info() {
fi
}

KUBECONFIG_PATH=$(search_kubeconfig)
KUBECONFIG_PATH=$(find_kubeconfig)

if [[ -n "${KUBECONFIG_PATH}" ]]; then
command -v kubectl > /dev/null && kubectl get --kubeconfig="${KUBECONFIG_PATH}" svc > "${COLLECT_DIR}"/kubelet/svc.log
Expand Down

0 comments on commit 0c21f2b

Please sign in to comment.