2
0
mirror of https://github.com/xcat2/confluent.git synced 2026-01-11 18:42:29 +00:00

Test connection on net cfg apply

When network configuration is applied, wait until we
can reach the deployment server again before exiting.

This should make us more robust against various potential delays after
changing the nature of network interfaces.
This commit is contained in:
Jarrod Johnson
2025-09-25 15:18:18 -04:00
parent 3505fe36e6
commit 39eb32df38

View File

@@ -567,4 +567,13 @@ if __name__ == '__main__':
if havefirewall:
subprocess.check_call(['systemctl', 'start', 'firewalld'])
await_tentative()
maxwait = 10
while maxwait:
try:
tclient = apiclient.HTTPSClient(checkonly=True)
tclient.check_connections()
break
except Exception:
maxwait -= 1
time.sleep(1)