Open riccardotommasini opened 7 years ago
I guess you would like to define multiple docker endpoints and then switch between them. This could be implemented but there would be a limitation: once you've changed docker endpoint the modification also applies to every other user connected to the same docker-compose-ui webapp.
This happens because the current implementation of docker-compose-ui to set a remote docker host is based on the DOCKER_HOST
env, just like the docker-compose cli.
If I understood, you mention a sort of docker host bookmarks that are also manageable from the UI. That would be enough for me.
I have also a question, how are you interacting with docker-compose. I imagine you import it as a library then you wrap the API to for a programmatic usage.
Would be possible to integrate this behavior with Docker-Py and instantiate client "manually": docker.DockerClient(base_url='host:port')
IDK if in this way you can keep the 100% compatibility with compose API though.
Hi @riccardotommasini I think you're right. I am actively investigating on how to implement this feature.
it should be quite easy to instantiate different clients to multiple docker hosts, my only concern is where to store the hosts list (since docker-compose-ui does not depend on a database).
Sounds naive, but I think you can keep them in memory as it is right now.
For persistence, how about a json format file in a directory that can be mounted on the host OS ?
Add the opportunity to connect multiple hosts at the same time