Reputation: 411
I've got 3 containers that will run on a single server, which we'll call: A,B,C
Each server has a script on the host that has the commands to start docker:
A_start.sh
B_start.sh
C_start.sh
I'm trying to create a swarm script to start them all, but not sure how.
ABC_start.sh
UPDATE: this seems to work, with the first being output to the terminal, cntrl+C exits out of them all.d
./A_start.sh & ./B_start.sh & ./C_start.sh
Upvotes: 2
Views: 3482
Reputation: 558
In bash,
you can do this:
nohup A_start.sh &
nohup B_start.sh &
nohup C_start.sh &
Upvotes: 0
Reputation: 24314
docker-compose
for that use case, its main purpose is to link containers properly, and bring them up, so your collection of scripts could end up being a single docker-compose up
command.Upvotes: 3