support kubespawner running on a IPv6 only cluster

This commit is contained in:
Steffen Vogel
2020-04-15 23:21:53 +02:00
parent aa459aeb39
commit 6283e7ec83
5 changed files with 25 additions and 11 deletions

View File

@@ -342,7 +342,7 @@ class Service(LoggingConfigurable):
env['JUPYTERHUB_SERVICE_PREFIX'] = self.server.base_url
hub = self.hub
if self.hub.ip in ('0.0.0.0', ''):
if self.hub.ip in ('', '0.0.0.0', '::'):
# if the Hub is listening on all interfaces,
# tell services to connect via localhost
# since they are always local subprocesses