我在AWS上配置Jupyter服务器时遇到一些问题 - 手动我能够做到这一点 - 但是,我需要通过Cloudformation脚本执行此操作
脚本运行得很好,但是当它们到达代码时它们会卡住并且cfn-init会挂起
service jupyter start
要么
jupyter notebook
要么
jupyter notebook &
笔记本启动,我能够登录到服务器 - 但是,cfn-init作业没有完成 - 控件没有返回到cfn-init来执行下一个语句
任何帮助将不胜感激
您可以通过查看/var/log/cfn-init.log来解决cfn-init故障。为了更详细,您可以将'-v'添加到调用cfn-init的userdata部分。例如:
"UserData" : { "Fn::Base64" :
{ "Fn::Join" : ["", [
"#!/bin/bash -xe\n",
"# Install the files and packages from the metadata\n",
"/opt/aws/bin/cfn-init -v ",
" --stack ", { "Ref" : "AWS::StackName" },
" --resource WebServerInstance ",
" --configsets InstallAndRun ",
" --region ", { "Ref" : "AWS::Region" }, "\n"
]]}
}