Skip to content

Commit

Permalink
Make provisioner ip configurable (jupyter-server#97)
Browse files Browse the repository at this point in the history
* make provisioner ip configurable

* bump version
  • Loading branch information
Steve Silvester authored and GitHub Enterprise committed Aug 25, 2021
1 parent b0c9edc commit 328a33b
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion data_studio_jupyter_extensions/_version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.5.0" # pragma: no cover
__version__ = "0.6.0" # pragma: no cover
8 changes: 4 additions & 4 deletions data_studio_jupyter_extensions/provisioner.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
class NotebookServiceProvisioner(provisioning.KernelProvisionerBase):
"""Kernel Provisioner that talks directly to the Notebook Service."""

ip = Unicode(allow_none=True)
ip = Unicode(allow_none=True).tag(config=True)
iopub_port = IntFromEnv(name=constants.IOPUBPORT, allow_none=True)
hb_port = IntFromEnv(name=constants.HBPORT, allow_none=True)
control_port = IntFromEnv(name=constants.CONTROLPORT, allow_none=True)
Expand Down Expand Up @@ -367,7 +367,7 @@ async def _launch_kernel_local_to_local(self) -> KernelConnectionInfo:

# Get the Host information from the kernel details endpoint.
kernel_info = await self.nbservice_client.get_kernel_details(self.process_id)
self.ip = kernel_info["host"]
self.ip = self.ip or kernel_info["host"]
return self.connection_info

async def _launch_kernel_local_to_cluster(
Expand All @@ -385,7 +385,7 @@ async def _launch_kernel_local_to_cluster(
self.control_port = port_map["control"]
self.shell_port = port_map["shell"]
self.stdin_port = port_map["stdin"]
self.ip = host
self.ip = self.ip or host
return self.connection_info

async def _launch_kernel_cluster_to_cluster(
Expand All @@ -397,7 +397,7 @@ async def _launch_kernel_cluster_to_cluster(
# The connection info should be predetermined by the kernel itself.
# Get the Host information from the kernel details endpoint.
kernel_info = await self.nbservice_client.get_kernel_details(self.process_id)
self.ip = kernel_info["host"]
self.ip = self.ip or kernel_info["host"]
return self.connection_info

async def launch_kernel(
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ testpaths = [
]

[tool.tbump.version]
current = "0.5.0"
current = "0.6.0"
regex = '''
(?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)
((?P<channel>a|b|rc|.dev)(?P<release>\d+))?
Expand Down
2 changes: 1 addition & 1 deletion version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.5.0
0.6.0

0 comments on commit 328a33b

Please sign in to comment.