[Update] Make some pathes more fail-safe and minor wording changes

master
andryyy 2021-10-18 11:42:09 +02:00
parent a7612e6c39
commit 0c3500f5ff
No known key found for this signature in database
GPG Key ID: 8EC34FF2794E25EF
1 changed files with 5 additions and 5 deletions

View File

@ -46,7 +46,7 @@ done
export LC_ALL=C
DATE=$(date +%Y-%m-%d_%H_%M_%S)
BRANCH=$(git rev-parse --abbrev-ref HEAD)
BRANCH=$(cd ${SCRIPT_DIR}; git rev-parse --abbrev-ref HEAD)
check_online_status() {
CHECK_ONLINE_IPS=(1.1.1.1 9.9.9.9 8.8.8.8)
@ -79,7 +79,7 @@ prefetch_images() {
docker_garbage() {
IMGS_TO_DELETE=()
for container in $(grep -oP "image: \Kmailcow.+" docker-compose.yml); do
for container in $(grep -oP "image: \Kmailcow.+" "${SCRIPT_DIR}/docker-compose.yml"); do
REPOSITORY=${container/:*}
TAG=${container/*:}
V_MAIN=${container/*.}
@ -121,9 +121,9 @@ docker_garbage() {
echo "Running image removal without extra confirmation due to force mode."
docker rmi ${IMGS_TO_DELETE[*]}
fi
fi
echo -e "\e[32mFurther cleanup...\e[0m"
echo "If you want to cleanup further garbage collected by Docker, please make sure all containers are up and running before cleaning your system by executing \"docker system prune\""
fi
}
in_array() {
@ -232,7 +232,7 @@ while (($#)); do
exit 0
;;
-f|--force)
echo -e "\e[32mForcing Update...\e[0m"
echo -e "\e[32mRunning in forced mode...\e[0m"
FORCE=y
;;
--no-update-compose)