美文网首页python跨坑技巧
centos7 配置安装 jupyterhub

centos7 配置安装 jupyterhub

作者: 爱睡觉的树 | 来源:发表于2019-03-25 16:02 被阅读0次

环境:  centos7

1 安装 node.js 略

2 安装 anaconda python3.7 略

pip install theano

 pip install jupyterhub

npm install -g configurable-http-proxy

3 创建 .jupyterhub目录

 4 jupyterhub --generate-config 生成配置文件

c.JupyterHub.ip ='0.0.0.0

c.JupyterHub.port = 9010

c.PAMAuthenticator.encoding = 'utf8'

c.LocalAuthenticator.create_system_users = True

c.Authenticator.whitelist = {'jptest1','jptest2','jptest3'}

c.Authenticator.admin_users = {'jpadmin'}

#c.Spawner.cmd=['jupyterhub-singleuser']

c.JupyterHub.statsd_prefix = 'jupyterhub'

5 shell终端

sudo groupadd jupyterhub

sudo useradd -g jupyterhub jpadmin 

(

useradd -c "用户注释" -g jupyterhub -d /home/用户目录 -s /bin/bash 用户名

这个是目前有效的方案,jupyterhub服务需以jupyterhub用户启动,否则无法获取PAM授权

)

sudo passwd jpadmin

 jupyterhub --no-ssl

 jupyterhub --ssl-key server_nopwd.key --ssl-cert server.crt

启动成功,这时候可以用系统用户登录了。

相关文章

网友评论

    本文标题:centos7 配置安装 jupyterhub

    本文链接:https://www.haomeiwen.com/subject/nnhbvqtx.html