A controller for mongodb cluster with serf.
- Docker
with root user:
cd /usr/bin/
wget https://raw.githubusercontent.com/wpjunior/mongodb-serf-ctl/master/mongodb-serf-ctl
chmod +x mongodb-serf-ctl
- Build the image (from: https://github.com/wpjunior/mongodb-serf)
mongodb-serf-ctl build
- Start first cluster
mongodb-serf-ctl start
- show cluster members
mongodb-serf-ctl status
- add more one router (mongos)
mongodb-serf-ctl start_router02
- add more one replicaset (mongod)
mongodb-serf-ctl start_rs3
- connect to mongodb shell
mongodb-serf-ctl shell