diff --git a/batchspawner/batchspawner.py b/batchspawner/batchspawner.py index fe05ad36..93b1bf27 100644 --- a/batchspawner/batchspawner.py +++ b/batchspawner/batchspawner.py @@ -588,6 +588,11 @@ async def start(self): if self.connect_to_job_cmd: await self.connect_to_job() + # Port and ip can be changed in connect_to_job, push out to jupyterhub. + if self.server: + self.server.port = self.port + self.server.ip = self.ip + self.db.commit() self.log.info( "Notebook server job {0} started at {1}:{2}".format(