diff options
| author | luisgulo <luisgulo@gmail.com> | 2025-11-25 00:53:48 +0100 |
|---|---|---|
| committer | luisgulo <luisgulo@gmail.com> | 2025-11-25 00:53:48 +0100 |
| commit | a1279db46447d1d5f9e1c7a86ab42197bbd0e7ae (patch) | |
| tree | 95e1b91ed41970e55a289b948de0b6e18373816f | |
| parent | b91acaeb9b435ced234276f5711a32596c99f68d (diff) | |
minor changes
| -rw-r--r-- | core/modules/ping.sh | 2 | ||||
| -rwxr-xr-x | shflow.sh | 12 |
2 files changed, 13 insertions, 1 deletions
diff --git a/core/modules/ping.sh b/core/modules/ping.sh index 79b72c6..b53564a 100644 --- a/core/modules/ping.sh +++ b/core/modules/ping.sh @@ -13,7 +13,7 @@ ping_task() { local count="${args[count]:-2}" local timeout="${args[timeout]:-3}" local target="${args[target]:-127.0.0.1}" - local become="${args[become]}" + local become="${args[become]:-true}" local prefix="" [ "$become" = "true" ] && prefix="sudo" @@ -284,7 +284,19 @@ run_for_host() { done local output exit_code + + #echo "DEPURANDO" + #echo "MODULO: ${MODULE}_task" + #echo "REMOTE_USER: $REMOTE_USER@$HOST_IP" + #echo "Argumentos: ${ARG_VALUES[@]}" + set +e + #if [[ "$HOST_IP" == "localhost" ]]; then + # output=$("${MODULE}_task" "${ARG_VALUES[@]}" 2>&1) + #else + # output=$("${MODULE}_task" "$REMOTE_USER@$HOST_IP" "${ARG_VALUES[@]}" 2>&1) + #fi + output=$("${MODULE}_task" "$REMOTE_USER@$HOST_IP" "${ARG_VALUES[@]}" 2>&1) exit_code=$? set -e |
