Skip to content

Commit

Permalink
Present both possible URL options as separate copy/pastable options
Browse files Browse the repository at this point in the history
Currently the default URL message given on the console on startup is:

---
Copy/paste this URL into your browser when you connect for the first time,
to login with a token:
     http://(myip.com or 127.0.0.1):8888/?token=8fdc8 ...
---

This will always need editing to use. Replace with one host IP (e.g. 'myip.com')
option and one local ip (127.0.0.1) option to make it copy/pastable again.
  • Loading branch information
einonm committed Oct 21, 2018
1 parent 643b992 commit f140ba9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion notebook/notebookapp.py
Original file line number Diff line number Diff line change
Expand Up @@ -1439,7 +1439,9 @@ def display_url(self):
if self.token:
# Don't log full token if it came from config
token = self.token if self._token_generated else '...'
url = url_concat(url, {'token': token})
url = (url_concat(url, {'token': token})
+ '\n or '
+ url_concat(self._url('127.0.0.1'), {'token': token}))
return url

@property
Expand Down

0 comments on commit f140ba9

Please sign in to comment.