blob: de3937c4b7de48737d68e49933912b77914e2c30 [file] [log] [blame]
Creating a new engine
In this chapter we have some exemples of how to create and work with an engine.
1. To create a new engine::
$ workon python-toolbox-env
$ marvin engine-generate
Respond the interactive prompt and wait for the engine environment preparation, and don’t forget to start dev box before if you are using vagrant.
2. Test the new engine::
$ workon <new_engine_name>-env
$ marvin
3. For more informations::
$ marvin --help
4. Youtube Tutorial
.. raw:: html
<iframe width="560" height="315" src="" frameborder="0" allowfullscreen></iframe>
MacOS Install
Toolbox will need some OS dependencies::
$ sudo easy_install pip
$ brew install openssl graphviz
We strongly recommend the use of VirtualEnv and VirtualEnvWrapper::
$ sudo pip install --upgrade pip
$ sudo pip install virtualenvwrapper --ignore-installed six
Spark installation (Optional)::
$ curl -o /tmp/spark-2.1.1-bin-hadoop2.6.tgz
$ sudo tar -xf /tmp/spark-2.1.1-bin-hadoop2.6.tgz -C /opt/
$ sudo ln -s /opt/spark-2.1.1-bin-hadoop2.6 /opt/spark
$ echo "export SPARK_HOME=/opt/spark" >> $HOME/.bash_profile
If you do not have /opt directory created, before unpacking spark, run::
$ sudo mkdir /opt
Marvin uses dafault values for these environment variables, but you can customize them (Optional)::
$ echo "export WORKON_HOME=$HOME/.virtualenvs" >> $HOME/.bash_profile
$ echo "export MARVIN_HOME=$HOME/marvin" >> $HOME/.bash_profile
$ echo "export MARVIN_DATA_PATH=$HOME/marvin/data" >> $HOME/.bash_profile
$ echo "source" >> $HOME/.bash_profile
$ source ~/.bash_profile
Install python-toolbox::
$ mkvirtualenv python-toolbox-env
$ setvirtualenvproject
$ pip install marvin-python-toolbox
Test the installation::
$ marvin