IPython NoteBook(jupyter)是一個綜合的交互式編程環境,比本來python命令進入的交互式環境要強大不少,總之就是炫酷加實用,瀏覽器中寫Python代碼,訪問源端linux服務器。
官網連接html
一、安裝依賴 安裝pip: yum install epel-release yum install python-pip python-devel 安裝開發工具集: yum groupinstall 'Development Tools' 二、安裝配置Jupyter pip install jupyter 運行: jupyter notebook Jupyter安裝成功,可是默認配置下只能從本地訪問(http://127.0.0.1:8888)。 若是你只在本機使用notebook,那麼下一個步能夠省了。若是你想把notebook作爲公共服務供其它人使用,配置容許遠程訪問: 生成配置文件: jupyter notebook --generate-config 生成的配置文件位於 ~/.jupyter/jupyter_notebook_config.py 生成自簽名SSL證書: cd ~/.jupyter openssl req -x509 -nodes -days 365 -newkey rsa:1024 -keyout notebook_cert.key -out notebook_cert.pem 生成一個密碼hash: python -c "import IPython;print(IPython.lib.passwd())" vim ~/jupyter/jupyter_notebook_config.py c = get_config() c.NotebookApp.certfile = u'/home/xxxx/.jupyter/notebook_cert.pem' c.NotebookApp.keyfile = u'/home/xxxx/.jupyter/notebook_cert.key' c.NotebookApp.password = u'sha1:991ec9cd2f39:522598e19891bab1ecaa3a9072e71f45811af9f2' c.NotebookApp.ip = '*' c.NotebookApp.port = 8080 c.NotebookApp.open_browser = False 再次啓動Notebook: jupyter notebook 若是你開啓了防火牆,配置打開8080端口。 使用瀏覽器訪問:https://your_domain_or_IP:8080
操做gif
node