diff options
author | Pedro Alvarez <pedro.alvarez@codethink.co.uk> | 2014-09-17 16:54:28 +0100 |
---|---|---|
committer | Pedro Alvarez <pedro.alvarez@codethink.co.uk> | 2014-09-17 16:54:28 +0100 |
commit | e594df7ed432d74cc56eaa5e29a1bfed7b22aae5 (patch) | |
tree | 3f91726ef415ebd7fed10e301287fe662e1ac7af /ansible/roles/trove-setup/tasks/known-hosts-setup.yml | |
parent | b2260b5fb45f4519bf7ea31ac278ffac7cddfbb7 (diff) | |
parent | 48a9bb48b428e08395179800359d264ef35b5c24 (diff) | |
download | trove-setup-e594df7ed432d74cc56eaa5e29a1bfed7b22aae5.tar.gz |
Merge branch 'baserock/pedroalvarez/allow-empty-upstream-trove3'
Reviewed-by: Richard Maw
Reviewed-by: Lars Wirzenius
Diffstat (limited to 'ansible/roles/trove-setup/tasks/known-hosts-setup.yml')
-rw-r--r-- | ansible/roles/trove-setup/tasks/known-hosts-setup.yml | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/ansible/roles/trove-setup/tasks/known-hosts-setup.yml b/ansible/roles/trove-setup/tasks/known-hosts-setup.yml index 6e988e0..a8d18f7 100644 --- a/ansible/roles/trove-setup/tasks/known-hosts-setup.yml +++ b/ansible/roles/trove-setup/tasks/known-hosts-setup.yml @@ -1,7 +1,10 @@ # Depends on: # - check.yml --- +# If UPSTREAM_TROVE is not defined, the jinja2 'default' filter will +# replace it with an empty string. ssh-keyscan skips empty hostnames, +# so it will run only with 'localhost' - name: Add localhost and UPSTREAM_TROVE to /etc/ssh/ssh_known_hosts shell: | - ssh-keyscan localhost {{ UPSTREAM_TROVE|quote }} > /etc/ssh/ssh_known_hosts + ssh-keyscan localhost {{ UPSTREAM_TROVE|default('')|quote }} > /etc/ssh/ssh_known_hosts creates=/etc/ssh/ssh_known_hosts |