How do I run Arangodb on Openshift?

While there are different database images available for OpenShift Container Platform users as described here , others, including Arangodb, are not yet available. I tried to install the official Arangodb container from Dcokerhub by running the following command using the Openshift CLI:

oc new-app arangodb

but it does not start successfully causing the following error:

chown: changing ownership of '/var/lib/arangodb3': Operation not permitted

      

It has to do with permissions. By default, OpenShift launches containers using a randomly assigned user ID, rather than as a root as described in Support Arbitrary User IDs . I tried to use directory and file permissions, which can be written by processes in the image to be owned by the root group, and read / written by that group in the Dockerfile:

RUN chgrp -R 0 /some/directory \
  && chmod -R g+rwX /some/directory

      

This time it throws the following error:

FATAL cannot set uid 'arangodb': Operation not permitted

      

Looking at the script that initializes arangodb (arangod script), arangodb works like arangodb: arangodb, which should (or maybe !!!) be arangodb: 0 in the case of Openshift.

Now I am really confused. I have read and searched a lot:

I also don't want to ask the cluster administrators to allow the project to run as root:

 # oadm policy add-scc-to-user anyuid -z default

      

The more I read, the more embarrassed I get. Has anyone done this before this can provide me with a docker container that I can run in Openshift?

+3


source to share





All Articles