From 2d58116014754fb76a7cbe376775c799ef6e8b34 Mon Sep 17 00:00:00 2001 From: sld-admin Date: Tue, 31 Mar 2026 22:39:04 +0100 Subject: [PATCH] Added the local-cache to avoiding the permission problem in /tmp --- installer/02_bashboard.sh | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/installer/02_bashboard.sh b/installer/02_bashboard.sh index d28eb25..d732af4 100644 --- a/installer/02_bashboard.sh +++ b/installer/02_bashboard.sh @@ -24,8 +24,9 @@ colorize() { function dashboard_fast() { #### CHANGABLE OPTIONS #### ISTHISVM=0 # Change to 1 if this is a VM. This will remove the temperature bit. - MIN_CHECK_IP=30 # Change this value to set the timing cache for checking the public IP + MIN_CHECK_IP=30 # Change this value to set the timing cache for checking the public IP. MIN_CHECK_UPDATE=120 # Change this value to set the timing cache for checking updates. + LOCAL_CACHE=1 # Change this value to 1 if you want to create the local cache in the ~/.bashrc.d/.dashboard_cache. @@ -41,7 +42,11 @@ function dashboard_fast() { #### Cache #### - CACHE_DIR="/tmp/.dashboard_cache" + if [ $LOCAL_CACHE -ne 0 ]; then + CACHE_DIR="/tmp/.dashboard_cache" + else + CACHE_DIR="/home/$(whoami)/.bashrc.d/.dashboard_cache" + fi mkdir -p "$CACHE_DIR" #### Overview ####