summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTobias Henkel <tobias.henkel@bmw.de>2019-01-08 15:56:40 +0100
committerTobias Henkel <tobias.henkel@bmw.de>2019-01-08 15:56:40 +0100
commite8dcc42c09f0f34a94abb433cdf3daebfd8b21c9 (patch)
tree5dce99ccece5e530663a3654ebcbdce3d6ab631f
parentfd53894f7388b8c26a7c3d2e9f9743e318ba23d3 (diff)
Default ssh keys to empty list
If the node doesn't have ssh keys defined we currently rely on nodepool adding an empty list of ssh keys. Instead be safe and default to an empty list. Change-Id: I1cbac643f47923b18959153f318d3d2fdc9626cd
Notes
Notes (review): Code-Review+2: David Shrewsbury <shrewsbury.dave@gmail.com> Code-Review+2: Monty Taylor <mordred@inaugust.com> Workflow+1: Monty Taylor <mordred@inaugust.com> Verified+2: Zuul Submitted-by: Zuul Submitted-at: Tue, 08 Jan 2019 15:53:16 +0000 Reviewed-on: https://review.openstack.org/629201 Project: openstack-infra/zuul Branch: refs/heads/master
-rw-r--r--zuul/executor/server.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/zuul/executor/server.py b/zuul/executor/server.py
index 0917f54..71f1c8a 100644
--- a/zuul/executor/server.py
+++ b/zuul/executor/server.py
@@ -1269,7 +1269,7 @@ class AnsibleJob(object):
1269 self.winrm_read_timeout 1269 self.winrm_read_timeout
1270 1270
1271 host_keys = [] 1271 host_keys = []
1272 for key in node.get('host_keys'): 1272 for key in node.get('host_keys', []):
1273 if port != 22: 1273 if port != 22:
1274 host_keys.append("[%s]:%s %s" % (ip, port, key)) 1274 host_keys.append("[%s]:%s %s" % (ip, port, key))
1275 else: 1275 else: