mirror of https://github.com/ansible/ansible.git
* avoid getting delegated vars w/o inventory host
fixes #75512
In the case of imports, we don't have a host, so getting host vars for
the delegated host makes no sense and should be avoided.
* also avoid error on vars_files with per host vars
* test
* testing given case
* oops
(cherry picked from commit 91319c5cfc
)
pull/75684/head
parent
49f0d06bd9
commit
9437c6f465
@ -0,0 +1,2 @@
|
||||
bugfixes:
|
||||
- variable manager, avoid sourcing delegated variables when no inventory hostname is present. This affects scenarios like syntax check and imports.
|
@ -0,0 +1 @@
|
||||
test
|
@ -0,0 +1,6 @@
|
||||
$ANSIBLE_VAULT;1.1;AES256
|
||||
63666636353064303132316633383734303731353066643832633666616162373531306563616139
|
||||
3038343765633138376561336530366162646332353132620a643661663366336237636562393662
|
||||
61656465393864613832383565306133656332656534326530346638336165346264386666343266
|
||||
3066336331313830310a666265653532643434303233306635366635616261373166613564326238
|
||||
62306134303765306537396162623232396639316239616534613631336166616561
|
@ -0,0 +1 @@
|
||||
- debug: msg='in role'
|
@ -0,0 +1,7 @@
|
||||
- name: "main"
|
||||
hosts: all
|
||||
gather_facts: false
|
||||
tasks:
|
||||
- import_role:
|
||||
name: some_role
|
||||
delegate_to: testhost
|
Loading…
Reference in New Issue