To get started with InvenioRDM, you need to install
command line tool for creating and updating your instance.
Some system requirements are needed beforehand:
- Python 3.6.2+ (Docker images are available for Python 3.6, 3.7 and 3.8.
- Python development headers. On Ubuntu:
sudo apt install python3-dev. On RHEL/Fedora:
yum install -y python3-devel.x86_64. On macOS: install XCode and activate the command line utilities.
- Node.js 14.0.0+ (needed for local installation)
- Docker 1.13.0+
- Docker-Compose 1.17.0+
- Cairo needed for badges to be properly displayed.
Other Python distributions
InvenioRDM targets CPython 3.6, 3.7 and 3.8 (lowest 3.6.2). Anaconda Python in particular is not currently supported and other Python distributions are not tested.
In addition, make sure the user that will be executing the CLI has access to
docker command (i.e. it is not only available for the root user):
sudo usermod --append --groups docker $USER
Most of these requirements can be automatically checked using the Invenio-CLI. Currently it is able to check Python, Node.js, Docker, Docker-Compose and Pipenv. If you are planning on doing development add the
invenio-cli check-requirements [--development]
Hardware and Docker requirements¶
We usually deploy the RDM on machines that have around 8GB of RAM and at least 4 cores.
On the same topic, make sure that Docker itself has enough memory to run.
In Linux based systems Docker can use all available memory. In OS X,
by default, it gets 2GB of RAM which most likely won't be enough. Allocating
6-8GB to it is optimal. You can do that in
Docker --> preferences --> resources
and adjust the
Memory to the corresponding value. If you have a few cores
more to spare, it might be a good idea to give more than 2. Take into account
that you will run between 4 and 8 containers.
Among the containers you will run is an Elasticsearch container which is quite demanding. Per Elasticsearch's Docker documentation, you will want to apply the following kernel setting:
On Linux, add the following to
/etc/sysctl.conf on your local machine (host machine):
# Maximum number of memory map areas a process (ElasticSearch) may have vm.max_map_count=262144
On macOS, do the following:
screen ~/Library/Containers/com.docker.docker/Data/com.docker.driver.amd64-linux/tty # and in the shell sysctl -w vm.max_map_count=262144
Install the CLI¶
Once you have installed these requirements, you can install the Invenio CLI package,
invenio-cli. The package is available on PyPI.
Use your favorite way to install a Python package:
pip install invenio-cli
pipenv install invenio-cli
pipx install invenio-cli
To make sure you've installed successfully:
invenio-cli, version 0.x.0