From: Zack Cerza Date: Fri, 22 May 2015 16:34:35 +0000 (-0600) Subject: Use Remote.hostname X-Git-Tag: 1.1.0~929^2~4 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=4df0bc628883e43f9296d552a1091b0001f28ef8;p=teuthology.git Use Remote.hostname Signed-off-by: Zack Cerza --- diff --git a/teuthology/task/ansible.py b/teuthology/task/ansible.py index 70138f965..fa6b1b953 100644 --- a/teuthology/task/ansible.py +++ b/teuthology/task/ansible.py @@ -161,7 +161,7 @@ class Ansible(Task): we're using an existing file. """ hosts = self.cluster.remotes.keys() - hostnames = [remote.name.split('@')[-1] for remote in hosts] + hostnames = [remote.hostname for remote in hosts] hostnames.sort() hosts_str = '\n'.join(hostnames + ['']) hosts_file = NamedTemporaryFile(prefix="teuth_ansible_hosts_", @@ -223,7 +223,7 @@ class Ansible(Task): """ Assemble the list of args to be executed """ - fqdns = [r.name.split('@')[-1] for r in self.cluster.remotes.keys()] + fqdns = [r.hostname for r in self.cluster.remotes.keys()] args = [ 'ansible-playbook', '-v', '-i', self.inventory,