You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to create a new database on init, but I'm only getting errors saying it's not connected.
Error:
ERROR JavaScript exception in file '/usr/share/arangodb3/js/client/modules/@arangodb/arango-database.js' at 388,40: ArangoError 2001: not connected\n! var requestResult = this._connection.POST(this._collectionurl() + urlAddon, body);\n! ^\nstacktrace: ArangoError: not connected\n at Proxy.ArangoDatabase._create (/usr/share/arangodb3/js/client/modules/@arangodb/arango-database.js:388:40)\n at (command-line):1:4\n
Hi,
by default the arangodb docker container doesn't bind unix domain sockets. You can however make it do so by specifying it should do (this example chooses to disable authentification for simplicity):
docker run -it -e ARANGO_NO_AUTH=1 --server.endpoint unix:///tmp/arangodb-tmp.sock
then your arangosh should be able to connect to that unix domain socket.
A nice addon is, that you could share that socket with your host if you mount the filesystem the socket is created on into the container using -v:
docker run -v /var/run/arangodb/:/tmp/ -it -e ARANGO_NO_AUTH=1 --server.endpoint unix:///tmp/arangodb-tmp.sock
you could then connect it from the host like that:
I'm trying to create a new database on init, but I'm only getting errors saying it's not connected.
Error:
docker-compose.yml
./docker/arangodb/Dockerfile
/docker-entrypoint-initdb.d/001-create-database.sh
The text was updated successfully, but these errors were encountered: