2015-10-28 20:25:23 +00:00
|
|
|
Installation
|
|
|
|
------------
|
2019-09-02 11:56:30 +00:00
|
|
|
The stable version can be used in two ways: as a system/user library through pip, or from a docker image.
|
2017-06-09 15:21:19 +00:00
|
|
|
|
2019-09-02 11:56:30 +00:00
|
|
|
Using docker is recommended because the image is self-contained, reproducible and isolated from the system, which means:
|
2017-06-09 15:21:19 +00:00
|
|
|
|
2019-09-02 11:56:30 +00:00
|
|
|
* It can be downloaded and run with just one simple command
|
2017-06-09 15:21:19 +00:00
|
|
|
* All dependencies are included
|
|
|
|
* It is OS-independent (MacOS, Windows, GNU/Linux)
|
|
|
|
* Several versions may coexist in the same machine without additional virtual environments
|
|
|
|
|
|
|
|
Additionally, you may create your own docker image with your custom plugins, ready to be used by others.
|
|
|
|
|
2015-10-28 20:25:23 +00:00
|
|
|
|
|
|
|
Through PIP
|
|
|
|
***********
|
|
|
|
|
|
|
|
.. code:: bash
|
|
|
|
|
2019-07-17 14:29:30 +00:00
|
|
|
pip install senpy
|
|
|
|
|
|
|
|
# Or with --user if you get permission errors:
|
2015-10-28 20:25:23 +00:00
|
|
|
|
2019-07-17 14:29:30 +00:00
|
|
|
pip install --user senpy
|
2015-10-28 20:25:23 +00:00
|
|
|
|
2019-07-17 14:29:30 +00:00
|
|
|
..
|
|
|
|
Alternatively, you can use the development version:
|
2015-10-28 20:25:23 +00:00
|
|
|
|
2019-07-17 14:29:30 +00:00
|
|
|
.. code:: bash
|
2015-10-28 20:25:23 +00:00
|
|
|
|
2019-07-17 14:29:30 +00:00
|
|
|
git clone git@github.com:gsi-upm/senpy
|
|
|
|
cd senpy
|
|
|
|
pip install --user .
|
2015-10-28 20:25:23 +00:00
|
|
|
|
2019-09-02 13:58:10 +00:00
|
|
|
Each version is automatically tested on GNU/Linux, macOS and Windows 10.
|
2019-09-02 11:56:30 +00:00
|
|
|
If you have trouble with the installation, please file an `issue on GitHub <https://github.com/gsi-upm/senpy/issues>`_.
|
|
|
|
|
|
|
|
|
2015-10-28 20:25:23 +00:00
|
|
|
Docker Image
|
|
|
|
************
|
2019-09-02 11:56:30 +00:00
|
|
|
|
|
|
|
The base image of senpy comes with some built-in plugins that you can use:
|
2017-03-28 10:34:39 +00:00
|
|
|
|
2017-04-03 16:18:35 +00:00
|
|
|
.. code:: bash
|
|
|
|
|
2019-01-07 11:08:19 +00:00
|
|
|
docker run -ti -p 5000:5000 gsiupm/senpy --host 0.0.0.0
|
2017-03-28 10:34:39 +00:00
|
|
|
|
2019-09-02 11:56:30 +00:00
|
|
|
To use your custom plugins, you can add volume to the container:
|
2017-03-28 10:34:39 +00:00
|
|
|
|
2017-04-03 16:18:35 +00:00
|
|
|
.. code:: bash
|
|
|
|
|
2019-01-07 11:08:19 +00:00
|
|
|
docker run -ti -p 5000:5000 -v <PATH OF PLUGINS>:/plugins gsiupm/senpy --host 0.0.0.0 --plugins -f /plugins
|
2017-06-09 15:21:19 +00:00
|
|
|
|
2017-03-28 10:34:39 +00:00
|
|
|
|
2017-04-03 16:18:35 +00:00
|
|
|
Alias
|
|
|
|
.....
|
|
|
|
|
|
|
|
If you are using the docker approach regularly, it is advisable to use a script or an alias to simplify your executions:
|
|
|
|
|
|
|
|
.. code:: bash
|
2017-03-28 10:34:39 +00:00
|
|
|
|
2019-01-07 11:08:19 +00:00
|
|
|
alias senpy='docker run --rm -ti -p 5000:5000 -v $PWD:/senpy-plugins gsiupm/senpy'
|
2017-04-03 16:18:35 +00:00
|
|
|
|
|
|
|
|
2017-06-09 15:21:19 +00:00
|
|
|
Now, you may run senpy from any folder in your computer like so:
|
2017-04-03 16:18:35 +00:00
|
|
|
|
2017-06-09 15:21:19 +00:00
|
|
|
.. code:: bash
|
2015-10-28 20:25:23 +00:00
|
|
|
|
2017-06-09 15:21:19 +00:00
|
|
|
senpy --version
|