less than 1 minute read

서버에서 jupyter notebook을 열 때, 설정해야 될 것들을 정리합니다.

1. ipython 실행

from IPython.lib import passwd

passwd()
# 비밀번호를 입력하면 확인된 비밀번호가 hash 값으로 나온다.
# Verify password가 나오면 저장해놓는다.

2. config 파일 만들기

$ jupyter notebook --generate-config
Writing default config to: /Users/sangchun/.jupyter/jupyter_notebook_config.py

jupyter_notebook_config.py 이 생성된다.

3. config 파일 수정

c = get_config()
c.NotebookApp.allow_remote_access = True
c.NotebookApp.ip = '*'
c.NotebookApp.password = 'sha1:972d2a21ff53:0e1110z34f41323bf1da439f1227e02bfdfbfc6bd'
# 위의 hash는 비밀번호 눌렀을 때 나온 hash

4. jupyter notebook 실행

Leave a comment