【6】网络与网页-7-waves-数据分析框架
一、简介
- 支持用户管理、任务管理、api调用
- 目前支持py2.7和 Django 1.11
二、安装
需求:
- python 2.7.X (WAVES-core is not yet compatible with python 3.5)
- pip package manager (required packages : python-pip python-dev build-essential)
- A web server: Apache or NGINX
- A database backend (Mysql or Postgres) but by default WAVES-core runs with sqlite
- yum install gcc
2.1 下载
cd /data/user/sam/project
git clone https://github.com/lirmm/waves-core.git waves
cd waves/
# 如需切换到某个特定的tags,可以
git checkout tags/[VERSION]
virtualenv venv
这个时候如果报错:
[sam@g02 waves]$ virtualenv venv
New python executable in /mnt/nfs/data/user/sam/project/waves/.venv/bin/python
ERROR: The executable /mnt/nfs/data/user/sam/project/waves/.venv/bin/python is not functioning
ERROR: It thinks sys.prefix is u'/usr' (should be u'/mnt/nfs/data/user/sam/project/waves/.venv')
ERROR: virtualenv is not compatible with this system or executable
出现问题的原因是我安装conda,改了virtualenv默认的环境,
[sam@c02 waves]$ which virtualenv
/data/software/anaconda2/bin/virtualenv
解决办法:
重新安装呗
pip uninstall virtualenv
conda install virtualenv
安装需要的包:
[sam@c02 waves]$ source venv/bin/activate
(venv) [sam@c02 waves]$ pip install -r requirements.txt
(.venv) user@host:~your_app$ ./manage.py check
(.venv) user@host:~your_app$ ./manage.py makemigrations wcore (may only display "No changes detected in app 'wcore'")
(.venv) user@host:~your_app$ ./manage.py migrate
(.venv) user@host:~your_app$ ./manage.py createsuperuser (then follow instructions)
(.venv) user@host:~your_app$ ./manage.py wqueue start
(.venv) user@host:~your_app$ ./manage.py runserver 0.0.0.0:8000
三、个性化调整
3.1 容许其他电脑访问
修改 waves_core/setting.py中
ALLOWED_HOSTS = ['*']
然后,
(.venv) user@host:~your_app$ ./manage.py runserver 0.0.0.0:8000
3.2 修改时区
修改 waves_core/setting.py中
TIME_ZONE = 'Asia/Shanghai'
3.3 本地化css和js
参考资料
- https://waves-core.readthedocs.io/en/latest/installation.html
- https://waves-core.readthedocs.io/en/latest/extensions.html
- https://www.biorxiv.org/content/10.1101/276485v1.full 《WAVES: a Web Application for Versatile Enhanced bioinformatic Services》
这里是一个广告位,,感兴趣的都可以发邮件聊聊:tiehan@sina.cn
个人公众号,比较懒,很少更新,可以在上面提问题,如果回复不及时,可发邮件给我: tiehan@sina.cn
个人公众号,比较懒,很少更新,可以在上面提问题,如果回复不及时,可发邮件给我: tiehan@sina.cn