I'm using docker compose to create a docker network, where my Web App and ArangoDB containers are working together. My goal is to restore Arango's data with arangorestore cli-tool, but I need to invoke it from inside my Web App code (from a python code actually - I'm developing with Django framework) where I don't have ArangoDB installed (which means arangorestore command could not be found by bash). How can I make ArangoDB execute arangorestore from another container?
Obviously, I don't want to install arangodb inside my Web App container (that's why i've separated them in the first place, according to official docker's recomendation - 1 service per container). So, i need to somehow connect to ArangoDB container and invoke arangorestore from there. I can imagine doing that over ssh, but it means installing openssh and messing around with keys. May be there are other options for me?
Containers can communicate with each other via port-forwarding, so I thought I could use it, but I don't know how.
I would appreciate if someone could help me.
SOLUTION:
According to Nikita's answer - there is an HTTP API for ArangoDB Enterprise, which allows to restore the backup over an http request. Seems to be the right solution if you care about app's architcture, but it requires proprietary software, so i guess this option is not for all.
arangorestorecommand available in the application image. There is no way for one container to run a command in another (without either the complexities of the ssh setup you describe or the gaping security issues of exposing the Docker socket to the container).