Binder允许创建自定义的计算环境,可以共享而被许多远端用户使用。

Binder融合多种开源技术:

  • repo2docker:由Github库快速生成docker镜像

  • JupyterHub:连接构建的docker镜像与云计算环境,提供web用户界面

  • BinderHub:粘合两种工具

Binder支持的配置文件列表:

  • Dockerfile

  • environment.yml

  • requirements.txt

  • REQUIRE

  • apt.txt

  • postBuild

  • runtime.txt

environment.yml

environment.yml是conda环境配置

channels:
  - conda-forge
  - defaults
dependencies:
  - matplotlib
  - pip:
    - sphinx-gallery

requirements.txt

在virtualenv或conda环境需要安装的Python包列表

numpy==1.7
matplotlib==2.1

REQUIRE

配置Julia包

PyPlot
Stats

apt.txt

应该安装的Debian包

cowsay
fortune

postBuild

当仓库构建完毕之后,运行的脚本命令

#!/bin/bash
wget <url-to-dataset>
python myfile.py

runtime.txt

安装的Python运行时,如果是使用Python 2,需要将python-2.7写入文件

python-2.7

【参考】

1。 Binder:https://mybinder.readthedocs.io/en/latest/index.html

2。Binder:use:https://mybinder.readthedocs.io/en/latest/using.html

results matching ""

    No results matching ""