Add docker availability check to all scripts that use docker commands
22 scripts used docker without verifying it's present. Consistent with the pattern already established in Docker_Essentials scripts. Added after acquire_lock and before detect_hosts in each script's setup section.
This commit is contained in:
@@ -60,6 +60,11 @@ validate_unraid_cmd \
|
||||
|
||||
acquire_lock
|
||||
|
||||
if ! command -v docker &>/dev/null; then
|
||||
error "Docker command not found"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
detect_hosts
|
||||
|
||||
[[ "$DRY_RUN" == true ]] && warn "DRY RUN — no stop scripts will be executed"
|
||||
|
||||
@@ -88,6 +88,11 @@ validate_unraid_cmd \
|
||||
"" "" \
|
||||
"unRAID notify script" || warn "unRAID notify script not found — native notifications disabled"
|
||||
|
||||
if ! command -v docker &>/dev/null; then
|
||||
error "Docker command not found"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
detect_hosts
|
||||
resolve_remote_ip
|
||||
|
||||
|
||||
@@ -72,6 +72,11 @@ fi
|
||||
|
||||
acquire_lock "wait"
|
||||
|
||||
if ! command -v docker &>/dev/null; then
|
||||
error "Docker command not found"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# detect_hosts() sets MY_ID and aliases all HOST*_TRANSCODE_* vars
|
||||
detect_hosts
|
||||
|
||||
|
||||
@@ -83,6 +83,11 @@ validate_unraid_cmd \
|
||||
|
||||
acquire_lock
|
||||
|
||||
if ! command -v docker &>/dev/null; then
|
||||
error "Docker command not found"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
detect_hosts
|
||||
resolve_remote_ip
|
||||
|
||||
|
||||
Reference in New Issue
Block a user