Debian Codegraph @

test/integration/targets/connection_ssh/check_ssh_defaults.yml

raw
1 - hosts: ssh
2 gather_facts: false
3 vars:
4 ansible_connection: ssh
5 ansible_ssh_timeout: 10
6 tasks:
7 - name: contain the madness
8 block:
9 - name: test all is good
10 ping:
11
12 - name: start the fun
13 meta: reset_connection
14
15 - name: now test we can use wrong port from ssh/config
16 ping:
17 ignore_unreachable: True
18 vars:
19 ansible_ssh_args: "-F {{playbook_dir}}/files/port_override_ssh.cfg"
20 register: expected
21
22 - name: check all is as expected
23 assert:
24 that:
25 - expected['unreachable']|bool
26 - "'2222' in expected['msg']"
27 always:
28 - name: make sure we don't cache the bad connection
29 meta: reset_connection