edx 题库编辑xblock的安装
2016-12-23 22:54
176 查看
1. 把xblock从 github仓库clone到edx机器,将所有者设为edxapp
git clone https://github.com/Heaven1881/mooc-ExerciseMdf.git sudo chown -R edxapp:edxapp mooc-ExerciseMdf
2. 把exercisemdf/static/index.html 文件中的iframe的src改为你的edx 域名
<iframe src="http://crl.ptopenlab.com:8811/static/exercisemdf/index.html" frameBorder=0 id="exercisemdf" width="100%" height="1000px" ></iframe>
改为
<iframe src="http://cherry.cs.tsinghua.edu.cn/static/exercisemdf/index.html" frameBorder=0 id="exercisemdf" width="100%" height="1000px" ></iframe>
3. 安装xblock
cd mooc-ExerciseMdf
sudo -u edxapp /edx/bin/pip.edxapp install .
4. 在文件夹/edx/var/edxapp/staticfiles/下新建文件夹exercisemdf/,并将文件夹staticfiles/下的文件夹拷贝到/edx/var/edxapp/staticfiles/中,同时增加所有人对其的读权限
$ sudo mkdir -p /edx/var/edxapp/staticfiles/exercisemdf
$ sudo cp -r staticfiles/* /edx/var/edxapp/staticfiles/exercisemdf/
$ sudo chmod a+r -R /edx/var/edxapp/staticfiles/exercisemdf/
5. 将github上的题库仓库clone到 /var/www/data/目录下。
注意:首先要把ssh key添加到github
添加ssh-key的方法为:
(1)首先切换到www-data用户
sudo -u www-data bash
(2)生成公钥私钥
ssh-keygen -t rsa -C "teacher@example.com"上面的邮箱可以换成自己的
(3)把生成的rsa_pub文件内容复制到github,添加ssh key
rsa_pub文件的路径在/var/www/.ssh/rsa_pub
ssh key添加好之后,接下来把github上的题库仓库clone到 /var/www/data/目录下
git clone git@github.com:chyyuu/os_course_exercise_library.git
6. 重启edx
sudo /edx/bin/supervisorctl restart edxapp:
7. 把该xblock添加到edx高级设置里。
登录到Studio,打开你的课程
settings->Advanced Setting
在"advanced_modules"的值后添加"exercisemdf"
8. 在课程的单元里可以添加“题库编辑组件”
如果输入题号,点“载入”能正常载入题目。
点保存,能正常保存修改,说明该xblock能正常工作
git clone https://github.com/Heaven1881/mooc-ExerciseMdf.git sudo chown -R edxapp:edxapp mooc-ExerciseMdf
2. 把exercisemdf/static/index.html 文件中的iframe的src改为你的edx 域名
<iframe src="http://crl.ptopenlab.com:8811/static/exercisemdf/index.html" frameBorder=0 id="exercisemdf" width="100%" height="1000px" ></iframe>
改为
<iframe src="http://cherry.cs.tsinghua.edu.cn/static/exercisemdf/index.html" frameBorder=0 id="exercisemdf" width="100%" height="1000px" ></iframe>
3. 安装xblock
cd mooc-ExerciseMdf
sudo -u edxapp /edx/bin/pip.edxapp install .
4. 在文件夹/edx/var/edxapp/staticfiles/下新建文件夹exercisemdf/,并将文件夹staticfiles/下的文件夹拷贝到/edx/var/edxapp/staticfiles/中,同时增加所有人对其的读权限
$ sudo mkdir -p /edx/var/edxapp/staticfiles/exercisemdf
$ sudo cp -r staticfiles/* /edx/var/edxapp/staticfiles/exercisemdf/
$ sudo chmod a+r -R /edx/var/edxapp/staticfiles/exercisemdf/
5. 将github上的题库仓库clone到 /var/www/data/目录下。
注意:首先要把ssh key添加到github
添加ssh-key的方法为:
(1)首先切换到www-data用户
sudo -u www-data bash
(2)生成公钥私钥
ssh-keygen -t rsa -C "teacher@example.com"上面的邮箱可以换成自己的
(3)把生成的rsa_pub文件内容复制到github,添加ssh key
rsa_pub文件的路径在/var/www/.ssh/rsa_pub
ssh key添加好之后,接下来把github上的题库仓库clone到 /var/www/data/目录下
git clone git@github.com:chyyuu/os_course_exercise_library.git
6. 重启edx
sudo /edx/bin/supervisorctl restart edxapp:
7. 把该xblock添加到edx高级设置里。
登录到Studio,打开你的课程
settings->Advanced Setting
在"advanced_modules"的值后添加"exercisemdf"
8. 在课程的单元里可以添加“题库编辑组件”
如果输入题号,点“载入”能正常载入题目。
点保存,能正常保存修改,说明该xblock能正常工作
相关文章推荐
- Open edX安装Xblock
- Open edX安装Xblock
- 1.4安装。编辑。卸载。删除其他插件
- 安装 xmlbuddy 插件到 Eclipse 3.0 以支持编辑 xml 文件
- 安装android编辑环境的一些方法
- OpenBSD 安装VIM编辑工具
- eclipse安装Veloeclipse(Velocity编辑插件)
- heritrix 下载、安装、配置、以及简单开发 编辑
- (PHP_002)PHP编辑IDE的开发环境的安装
- 1、4安装。编辑。卸载。删除其他插件
- eclipse下安装js插件:spket(支持Ext编辑)
- Eclipse Visual Editor 可视化/图形Gui编辑/设计插件的安装篇
- sharepoint 关于 在数据表中编辑 share point server 2003 在数据表中编辑 未安装与 Windows SharePoint Services 兼容的数据表组件。
- 【编辑】linux pxe安装服务器搭建
- eclipse编辑velocity和html工具eclipsewebedit下载与安装
- .Net 编辑利器 Fckeditor 2.6.6 安装使用
- Web开发与JavaScript编辑利器——Aptana Studio简介、安装、破解、汉化
- netbeans和vi插件的安装以及编辑配色方案
- n900成为掌上电脑!流畅运行lxde,openoffice编辑,scim中文输入(f附安装程序)
- 安装OFFICE的时候,弹出提示框“阻止访问注册表编辑工具”