2: 2020-08-21 (金) 17:45:56 iseki |
3: 2020-08-23 (日) 02:49:18 iseki |
| # Use JupyterHub.bind_url | | # Use JupyterHub.bind_url |
| #c.JupyterHub.base_url = '/' | | #c.JupyterHub.base_url = '/' |
| + | |
| + | # My IP Address |
| + | my_ip_addr = '192.168.27.40' |
| | | |
| ## The public facing URL of the whole JupyterHub application. | | ## The public facing URL of the whole JupyterHub application. |
| # | | # |
| # This is the address on which the proxy will bind. Sets protocol, ip, base_url | | # This is the address on which the proxy will bind. Sets protocol, ip, base_url |
- | c.JupyterHub.bind_url = 'http://192.168.27.20:8000' | + | c.JupyterHub.bind_url = 'http://'+my_ip_addr+':8000' |
| | | |
| ## Whether to shutdown the proxy when the Hub shuts down. | | ## Whether to shutdown the proxy when the Hub shuts down. |
| # | | # |
| # .. versionadded:: 0.9 | | # .. versionadded:: 0.9 |
- | c.JupyterHub.hub_bind_url = 'http://192.168.27.20:8081' | + | c.JupyterHub.hub_bind_url = 'http://'+my_ip_addr+':8081' |
| | | |
| ## The ip or hostname for proxies and spawners to use for connecting to the Hub. | | ## The ip or hostname for proxies and spawners to use for connecting to the Hub. |
| # | | # |
| # .. versionadded:: 0.8 | | # .. versionadded:: 0.8 |
- | c.JupyterHub.hub_connect_ip = '192.168.27.20' | + | c.JupyterHub.hub_connect_ip = my_ip_addr |
| | | |
| ## DEPRECATED | | ## DEPRECATED |
| # See `hub_connect_ip` for cases where the bind and connect address should | | # See `hub_connect_ip` for cases where the bind and connect address should |
| # differ, or `hub_bind_url` for setting the full bind URL. | | # differ, or `hub_bind_url` for setting the full bind URL. |
- | #c.JupyterHub.hub_ip = '192.168.27.20' | |
| #c.JupyterHub.hub_ip = '127.0.0.1' | | #c.JupyterHub.hub_ip = '127.0.0.1' |
| c.JupyterHub.hub_ip = '0.0.0.0' | | c.JupyterHub.hub_ip = '0.0.0.0' |
| # .. deprecated: 0.9 | | # .. deprecated: 0.9 |
| # Use JupyterHub.bind_url | | # Use JupyterHub.bind_url |
- | c.JupyterHub.ip = '192.168.27.20' | + | c.JupyterHub.ip = my_ip_addr |
| | | |
| ## Supply extra arguments that will be passed to Jinja environment. | | ## Supply extra arguments that will be passed to Jinja environment. |
| # "coursewarehub": "niicloudoperation/jupyterhub-singleuser", | | # "coursewarehub": "niicloudoperation/jupyterhub-singleuser", |
| #} | | #} |
- | c.DockerSpawner.remove = True | + | #c.DockerSpawner.remove = True |
- | c.DockerSpawner.extra_create_kwargs = {'user': 'root'} | + | #c.DockerSpawner.extra_create_kwargs = {'user': 'root'} |
| #c.DockerSpawner.extra_host_config = {'runtime': 'nvidia'} | | #c.DockerSpawner.extra_host_config = {'runtime': 'nvidia'} |
| c.Spawner.environment = {'GRANT_SUDO': 'yes'} | | c.Spawner.environment = {'GRANT_SUDO': 'yes'} |
- | notebook_dir = '/home/jovyan/work' | + | #notebook_dir = '/home/jovyan/work' |
- | c.DockerSpawner.notebook_dir = notebook_dir | + | #c.DockerSpawner.notebook_dir = notebook_dir |
- | c.DockerSpawner.volumes = { 'jupyterhub-user-{username}': notebook_dir } | + | #c.DockerSpawner.volumes = { 'jupyterhub-user-{username}': notebook_dir } |
| | | |
| #from jupyter_client.localinterfaces import public_ips | | #from jupyter_client.localinterfaces import public_ips |
| # path! They can do so with many other means. | | # path! They can do so with many other means. |
| #c.Spawner.notebook_dir = '/home/jupyter' | | #c.Spawner.notebook_dir = '/home/jupyter' |
- | c.Spawner.notebook_dir = '~/notebook' | + | #c.Spawner.notebook_dir = '/notebook' note set! it is because, this has bug! |
| | | |
| ## An HTML form for options a user can specify on launching their server. | | ## An HTML form for options a user can specify on launching their server. |