Post-install setup
To customize the InvenioRDM and fits its needs, the GEO Knowledge Hub defines new Rest API endpoints, operations, look-and-feel and more. One element of this customization are GEO-specific roles, users and access policies.
The helm-invenio chart deploys the application and services, but it does not seed these specific elements required by the GEO Knowledge Hub. So, in this page, we will walk you through the commands you should run after the helm install to seed the GEO Knowledge Hub specific elements.
1. Access the worker
Section titled “1. Access the worker”To run the commands below, you need to access a shell inside a worker pod. You can do this with the following command:
kubectl exec -it -n invenio deploy/invenio-worker -- /bin/bash2. Initialise the database
Section titled “2. Initialise the database”To initialise the database, you need to run the following command:
invenio db initinvenio db create3. Create the default file storage location
Section titled “3. Create the default file storage location”To create the default file storage location, you need to run the following command:
invenio files location --default 'default-location' /opt/invenio/var/instance/dataThis command creates a new file storage location called default-location and points it to the a local directory.
If you have a distributed storage system, you might need to use a different path. The command bellow shows one example using an s3-compatible storage system:
invenio files location --default 'default-location' s3://my-bucket/dataMore information about the invenio files location can be found in the InvenioRDM documentation.
4. Create the GEO Knowledge Hub roles
Section titled “4. Create the GEO Knowledge Hub roles”The GEO Knowledge Hub extends the InvenioRDM with three GEO-specific roles: geo-community, geo-provider and geo-secretariat. To create these roles, you need to run the following commands:
invenio roles create admininvenio roles create geo-communityinvenio roles create geo-providerinvenio roles create geo-secretariatThen grant the relevant access policies:
invenio access allow superuser-access role admininvenio access allow geo-provider-access role geo-provider5. Promote your admin user
Section titled “5. Promote your admin user”If you defined invenio.default_users, the install job will have created the user already. If you want, you can promote them to a GEO-specific role.
# invenio roles add <email> <role>invenio roles add admin@invenio.org {geo-provider, geo-secretariat, geo-community}6. Initialise the search indices and load fixtures
Section titled “6. Initialise the search indices and load fixtures”Now you have the database and users ready, you can initialise the search indices and load the fixtures.
invenio index initNext, let’s purge the index queue and initialise it:
invenio index queue init purgeFinally, let’s load the fixtures:
invenio rdm-records fixturesThis command will start jobs for workers to process and index controlled vocabularies used in the GEO Knowledge Hub, including resource types, languages, licenses, GEO Work Programme activities, engagement priorities, target audiences and more. This will take a few minutes to complete.
Next steps
Section titled “Next steps”1) Try the REST API examples against your fresh instance.
2) Review the parameters reference to fine-tune resource limits, autoscaling, and bundled-services credentials.