Skip to content

Install REP with Docker [Mac OS X, Windows]

Andrey Ustyuzhanin edited this page Aug 10, 2016 · 1 revision

To install REP it may take some time and courage since it depends on plenty of stuff. To get to your data analytics experience quickly we've loaded docker images with all the necessary packages, so you just need to pull and run them.

Prerequisites:

Install docker toolbox

Steps (Kitematic):

  1. Run Kitematic, which is part of docker toolbox
  2. Press ‘+New’ button
  3. find ‘yandex/rep’ image in the list
  4. press ‘Create’ button
  5. as soon as it downloads and starts you can open Jupyter interface by clicking on ‘Settings -> Ports’ and going to IP:Port mentioned there.

Console-based alternative (Mac OS X)

if you would like as soon as you have installed docker toolbox, you can start it from console:

docker-machine start default # starting VM
eval $(docker-machine env default)
docker pull yandex/rep:latest
git pull https://github.com/yandex/rep.git
cd rep
make run # for REP interactive start or
make run-daemon # to run REP in the background

Tuning

There are set of things you can tweak to improve your experience:

  • mount your local folder to /notebooks within docker
  • mount configuration folder to /etc_external folder within docker (it could hold SSL certificate and modules you’d like to be installed by Jupyter start)
    • if there is modules folder below, before starting jupyter the starting script looks for modules directories there to be installed by pip install <>, and if there is requirements.txt, it will be installed by pip as well.

parameters you can change through environment variables

  • GENERATE_SSL_HOSTNAME — generate SSL certificate and run with SSL support
  • SSL_CERTFILE — SSL certificatie, relative to docker container (say /etc_external/mycert.pem)
  • SSL_KEYFILE — SSL certificate key
  • PASSWORD — string to be used as password to access Jupyter
  • SECRET — string to be used as secret key to check Jupyter notebooks
  • SECRET_FILE — secret file name, relative to docker container
  • JUPYTER_PORT — port to be used by Jupyter

you can change those settings either in Kitematic container ‘setting’ interface or set those environment variables before running REP from console.

Troubleshooting

Diagnostics is saved in jupyter.log in the root folder shown by Jupyter or you can look it by make logs command