1543
This commit is contained in:
@@ -2660,7 +2660,7 @@
|
||||
sshpass -f "{{ dev2_passfile_used }}" ssh {{ ssh_opts_common }} \
|
||||
-o ConnectTimeout={{ ssh_timeout }} \
|
||||
-p "$PORT" "{{ dev2_ssh_user }}@127.0.0.1" \
|
||||
"grep -i block -A2 /tmp/config.json 2>/dev/null | grep enab | head -n1 | grep -Eo 'true|false' | head -n1 || true"
|
||||
"cat /tmp/config.json 2>/dev/null | grep -i block -A2 | grep enab | head -n1"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
@@ -2669,7 +2669,7 @@
|
||||
-o StrictHostKeyChecking=no -o PubkeyAuthentication=no \
|
||||
-o ConnectTimeout=15 \
|
||||
"{{ dev2_ssh_user }}@{{ lldp_dev2_ip }}" \
|
||||
"grep -i block -A2 /tmp/config.json 2>/dev/null | grep enab | head -n1 | grep -Eo 'true|false' | head -n1 || true"
|
||||
"cat /tmp/config.json 2>/dev/null | grep -i block -A2 | grep enab | head -n1"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
@@ -2682,7 +2682,7 @@
|
||||
-o StrictHostKeyChecking=no -o PubkeyAuthentication=no \
|
||||
-o ConnectTimeout={{ ssh_timeout }} \
|
||||
'{{ dev2_ssh_user }}@\[${IP6}%{{ dev1_iface }}\]' \
|
||||
\"grep -i block -A2 /tmp/config.json 2>/dev/null | grep enab | head -n1 | grep -Eo 'true|false' | head -n1 || true\""
|
||||
\"cat /tmp/config.json 2>/dev/null | grep -i block -A2 | grep enab | head -n1\""
|
||||
exit 0
|
||||
fi
|
||||
|
||||
@@ -2697,7 +2697,16 @@
|
||||
- name: Dev2 | Normalize payredirect value
|
||||
delegate_to: localhost
|
||||
vars:
|
||||
payredirect_raw_clean: "{{ dev2_payredirect_raw.stdout | default('') | trim | lower }}"
|
||||
payredirect_raw_clean: >-
|
||||
{{
|
||||
'true'
|
||||
if 'true' in (dev2_payredirect_raw.stdout | default('') | lower)
|
||||
else (
|
||||
'false'
|
||||
if 'false' in (dev2_payredirect_raw.stdout | default('') | lower)
|
||||
else ''
|
||||
)
|
||||
}}
|
||||
set_fact:
|
||||
payredirect_value: >-
|
||||
{{
|
||||
@@ -2752,7 +2761,7 @@
|
||||
delegate_to: localhost
|
||||
set_fact:
|
||||
non_ts_diff_found: true
|
||||
changed_when: false
|
||||
changed_when: false
|
||||
|
||||
# ----------------------- Dev2 indoor_ip resolution (ppp0/eth0.4000 preferred) -----------------------
|
||||
- name: Indoor | Compute fallback connected IP (as used for Dev2 reachability)
|
||||
|
||||
Reference in New Issue
Block a user