Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Another Docker container should inherit with `FROM jupyter/notebook`
# to run actual services.
#
# For opinionated stacks of ready-to-run Jupyter applications in Docker,
# For opinionated stacks of ready-to-run Jupyter applications in Docker,
# check out docker-stacks <https://github.com/jupyter/docker-stacks>

FROM jupyter/ubuntu_14_04_locale_fix
Expand Down Expand Up @@ -109,4 +109,4 @@ WORKDIR /notebooks
EXPOSE 8888

ENTRYPOINT ["tini", "--"]
CMD ["jupyter", "notebook", "--no-browser"]
CMD ["jupyter", "notebook", "--no-browser", "--allow-root"]
7 changes: 4 additions & 3 deletions notebook/tests/launchnotebook.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class TimeoutError(Exception):

class NotebookTestBase(TestCase):
"""A base class for tests that need a running notebook.

This create some empty config and runtime directories
and then starts the notebook server with them.
"""
Expand All @@ -60,7 +60,7 @@ def wait_until_alive(cls):
return

raise TimeoutError("The notebook server didn't start up correctly.")

@classmethod
def wait_until_dead(cls):
"""Wait for the server process to terminate after shutdown"""
Expand All @@ -85,7 +85,7 @@ def setup_class(cls):
cls.data_dir = data_dir
cls.runtime_dir = TemporaryDirectory()
cls.notebook_dir = TemporaryDirectory()

started = Event()
def start_thread():
app = cls.notebook = NotebookApp(
Expand All @@ -98,6 +98,7 @@ def start_thread():
notebook_dir=cls.notebook_dir.name,
base_url=cls.url_prefix,
config=cls.config,
allow_root=True,
)
# don't register signal handler during tests
app.init_signal = lambda : None
Expand Down
2 changes: 1 addition & 1 deletion notebook/tests/test_notebookapp.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ def test_nb_dir_root():
def test_generate_config():
with TemporaryDirectory() as td:
app = NotebookApp(config_dir=td)
app.initialize(['--generate-config'])
app.initialize(['--generate-config', '--allow-root'])
with nt.assert_raises(NoStart):
app.start()
assert os.path.exists(os.path.join(td, 'jupyter_notebook_config.py'))
Expand Down