Run a service from docker-compose on remote server

Hi.

I want to run a docker-compose which has 6 services (eg. an elasticsearch cluster) now i want to some of these services be run on a remote server while the main docker-compose run in my host.

how can i do that and what subjects should i know for it?

Note that just bec ause Docker Compose containers is on your machine, you won’t be able to mount files from there. All you get is a way to instruct the daemon.

And unless you are using Docker Desktop which configures docker-compose to be an alias to docker compose, use the docker compose command as the other uses an old compose.

1 Like

Did you read about Docker Swarm?

I heard about it and test a simple thing. but it didn’t work. and i do not know to read complete guide to use it.