我在" / etc / apache2 / sites-enabled"中有以下条目:在我的Ubuntu 15.10上
<VirtualHost *:80>
ServerName "jupyter.xxxxxxxxxxxx.com"
ProxyPass / http://192.168.254.23:8888/
ProxyPassReverse / http://192.168.254.23:8888/
Header edit Origin "jupyter.xxxxxxxxxxxx.com" 192.168.254.23:8888
RequestHeader edit Origin "jupyter.xxxxxxxxxxxx.com" 192.168.254.23:8888
Header edit Referer "jupyter.xxxxxxxxxxxx.com" 192.168.254.23:8888
RequestHeader edit Referer "jupyter.xxxxxxxxxxxx.com" 192.168.254.23:8888
<Location ~ "/(user/[^/]*)/(api/kernels/[^/]+/channels|terminals/websocket)/?">
ProxyPass ws://192.168.254.23:8888/
ProxyPassReverse ws://192.168.254.23:8888/
</Location>
</VirtualHost>
完成上述条目后,我重新启动了apache:&#34; sudo service apache2 restart&#34;
当我尝试运行我的脚本时,内核无法连接。
控制台日志:
当我指定IP地址时,同样有效:
以下是有关我的设置的更多信息:
而且,我正在家庭网络中对此进行测试,因此无需担心代理或ISP。我在/ etc / hosts
中有以下条目192.168.254.201 jupyter.xxxxxxxxxxxx.com