NRP Docker Install
Note! You can find this guide in our documentation pages as well here.
This installation mode is for users who want to try out the Neurorobotics Platform locally on their machine, clone template experiments, or create new ones based on our template models. More expert users or developers who might want to change code directly in the Platform or add Gazebo plugins and robot controllers should install the Platform from source instead.
This installation uses Docker as the underlying package manager. It is technically possible for users to open a shell in the containers and hack them, but they must be aware that containers are replaced on Platform updates and all there changes inside containers will be lost. Of course, all user data, custom experiments and models are safe and kept between updates!
Linux/Mac users, skip this part.
- Windows users have to first install WLS (Windows Linux Subsystem) and a brand of Linux on top of it from the Windows Store (we tested with Ubuntu 16.04 and Ubuntu 18.04). See here for instructions.
- Open an Linux terminal from the Windows start menu (in our case an Ubuntu menu item) and proceed with the next step.
NB: Linux/Windows users, skip this part.
(Note on MacOS only docker versions >= 18.03 are supported)
- Add an alias into your hosts file:
- Restart your computer.
echo "127.0.0.1 host.docker.internal" | sudo tee -a /etc/hosts
INSTALL WITH DOCKER
This install procedure should work on any Linux OS, MacOS (with docker version >=18.03) and on Windows 10 if you did the preparatory part. Other operating systems have not been tested and it is likely they will not work with this bash script.
- The first step is to install Docker on your system (on Windows, install it in Windows, not in the WSL Ubuntu). Use the Docker installation guides for your system. If you’re using Linux OS, for your convenience, we recommend to allow the Docker to run as non-root user, otherwise put an eye on a note at the end of the paragraph.
- Then download the following script. Although the script should auto-update itself later when needed, we recommend to download the fresh one manually when you wish to install/reinstall the NRP. In case any errors occur during the installation, please, download the fresh script with this link.
- The following steps will install and configure the Docker images of the NRP on your system (assuming that Docker can run as a non-root user). Your user data will be stored in Docker volumes. So everything is cleanly self contained. You just need to specify the release type of the NRP.
chmod 755 nrp_installer.sh ./nrp_installer.sh install VERSION # Option 1: ./nrp_installer.sh install latest # Option 2: ./nrp_installer.sh install legacy
In order to install the latest release of the NRP (Python 3.8 compatible) use latest as VERSION.
In case the VERSION parameter is set to legacy, then the script installs the legacy release of the NRP (v3.0.5 - Python 2.7 compatible).
Note, that omitting VERSION parameter forces the script to install the latest release of the NRP.
You can run the script without any arguments to get a list of other options, e.g. uninstall, restart, connect to containers (open a bash inside them) etc.
NOTE: In case for security reasons you do not want to grant the Docker privileges to be run as a non-root user, add -s option for the nrp_installer.sh after the command, i.e.: ./nrp_installer.sh install latest -s. This option runs the installation with required sudo privileges.
NB: This step might only be necessary for users who own a SpiNNaker board and want to connect this board with the Neurorobotics Platform (NRP).
By default, the NRP works with a 4-chip SpiNNaker board using the standard IP-address as shown here. To change the standard settings, please follow these steps:
./nrp_installer.sh connect_backend # Open a new terminal and enter nano ~/.spynnaker.cfg # Modify the IP-address and board settings in the text file (more information on how to change the settings can be found here) # Back in the old terminal enter ./nrp_installer.sh restart
CONNECT TO THE NEUROROBOTICS PLATFORM
After running the script, to connect to the platform open your browser (Firefox and Chrome are officially supported) and go to the following link: http://localhost:9000/#/esv-private .
You will be prompted to enter a username and password. On local installs like this one, there is a default user "nrpuser" and password "password". Creating new users is currently not possible from the user interface.
Warning with low-bandwidth networks
This install procedures involves downloading a couple of GBs from the internet. Public wifi or slow connections will take a long time or possibly fail.
If there are troubles setting up the docker network, you can try a different subnet by changing it in the installer script.
In Windows install, communication with the docker daemon has been reported. In that case, follow this: - check the setting "expose deamon on tcp://localhost:2375" in Docker - then in Ubuntu add the line
at the bottom of your .bashrc (use the nano editor for example).
Since docker desktop 2.2.0, the Windows post-install step seems to not work anymore (see https://github.com/docker/for-win/issues/5538). We are working on it.