2
0
mirror of https://github.com/xcat2/confluent.git synced 2024-11-26 03:19:48 +00:00

Fix osdeploy initialize in no-domain environment

If no domain is defined, then do not try to append
This commit is contained in:
Jarrod Johnson 2020-08-05 16:31:08 -04:00
parent 0a3936164e
commit 8d48fc3273

View File

@ -60,7 +60,7 @@ def local_node_trust_setup():
neededlines = set([
'HostbasedAuthentication yes', 'HostbasedUsesNameFromPacketOnly yes',
'IgnoreRhosts no'])
if not myname.endswith(domain):
if domain and not myname.endswith(domain):
myprincipals.add('{0}.{1}'.format(myname, domain))
for pubkey in glob.glob('/etc/ssh/ssh_host_*key.pub'):
currpubkey = open(pubkey, 'rb').read()