mirror of
https://github.com/ansible-collections/ansible.posix.git
synced 2026-01-11 23:25:28 +01:00
Compare commits
2 commits
03a606a494
...
ed2b68077e
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ed2b68077e | ||
|
|
3fe65ff1b1 |
1 changed files with 6 additions and 2 deletions
|
|
@ -342,7 +342,9 @@ class ActionModule(ActionBase):
|
||||||
|
|
||||||
# Determine if we need a user@ and a password
|
# Determine if we need a user@ and a password
|
||||||
user = None
|
user = None
|
||||||
password = task_vars.get('ansible_ssh_pass', None) or task_vars.get('ansible_password', None)
|
password = (task_vars.get('ansible_ssh_password', None)
|
||||||
|
or task_vars.get('ansible_ssh_pass', None)
|
||||||
|
or task_vars.get('ansible_password', None))
|
||||||
if not dest_is_local:
|
if not dest_is_local:
|
||||||
# Src and dest rsync "path" handling
|
# Src and dest rsync "path" handling
|
||||||
if boolean(_tmp_args.get('set_remote_user', 'yes'), strict=False):
|
if boolean(_tmp_args.get('set_remote_user', 'yes'), strict=False):
|
||||||
|
|
@ -372,7 +374,9 @@ class ActionModule(ActionBase):
|
||||||
src = self._process_origin(src_host, src, user)
|
src = self._process_origin(src_host, src, user)
|
||||||
dest = self._process_remote(_tmp_args, dest_host, dest, user, inv_port in localhost_ports)
|
dest = self._process_remote(_tmp_args, dest_host, dest, user, inv_port in localhost_ports)
|
||||||
|
|
||||||
password = dest_host_inventory_vars.get('ansible_ssh_pass', None) or dest_host_inventory_vars.get('ansible_password', None)
|
password = (dest_host_inventory_vars.get('ansible_ssh_password', None)
|
||||||
|
or dest_host_inventory_vars.get('ansible_ssh_pass', None)
|
||||||
|
or dest_host_inventory_vars.get('ansible_password', None))
|
||||||
if self._templar is not None:
|
if self._templar is not None:
|
||||||
password = self._templar.template(password)
|
password = self._templar.template(password)
|
||||||
else:
|
else:
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue