Archived
Fix duplicate-host check reporting false SSH failures
Check NixOS configurations / eval-hosts (pull_request) Failing after 11m38s
Check NixOS configurations / eval-hosts (pull_request) Failing after 11m38s
The remote bash script run over SSH ended with a for-loop whose last statement was `[[ "$n" == "$target" ]] && echo ...`. When the last VM/CT checked on the node didn't match --host, that test evaluated false and became the exit status of the whole remote script (1) -- which the wrapper then misreported as "couldn't reach the node", even though SSH connectivity and the check itself were both fine. The actual signal is the script's stdout, not its exit code, so end it with an explicit exit 0. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -320,6 +320,7 @@ for id in $(pct list 2>/dev/null | awk 'NR>1{print $1}'); do
|
||||
n="$(pct config "$id" 2>/dev/null | grep -oP '^hostname:\s*\K\S+' || true)"
|
||||
[[ "$n" == "$target" ]] && echo "lxc ${id} ${n}"
|
||||
done
|
||||
exit 0
|
||||
REMOTE_SCRIPT
|
||||
)" || ssh_check_status=$?
|
||||
if [[ "$ssh_check_status" -ne 0 ]]; then
|
||||
|
||||
Reference in New Issue
Block a user