Skip to content

sstave/elastic-mongodb

 
 

Repository files navigation

elastic-mongodb

MongoDB oschestration based on SaltStack.

Tested with

HOWTO

  • Set replset_name and replset_role grains to every minion.
  • Roles must be primary or secondary. Only one minion can be primary per set.

Master/SaltCloud install:

apt-get install python-pip git
pip install apache-libcloud==0.13.2
wget -O - http://bootstrap.saltstack.org | sh -s -- -M -N
pip install -e git+https://github.com/vhgroup/[email protected]#egg=salt-cloud

Setup provider, profile and map. See examples below.

ssh to master

salt \* test.ping
salt \* grains.item replset_role replset_name
apt-get install git
git clone https://github.com/vhgroup/elastic-mongodb.git
cd elastic-mongodb
cp -a file_root/ /srv/salt

ROADMAP

  • Basic replica set configuration. DONE
  • Basic sharding support. DONE
  • Sharding + Repl sets. DONE
  • Bootstrap script.
  • Salt cloud integration.
  • Support for delayed replica set members.
  • Implement Salt overstate.

TODO

  • Create dependencies between minions. For example, primary configuration fails if secondaries doesn't have the grains replset_name and replset_role. May be not required, use conditionals in templates.

  • tests!!!

  • mine_functions should accept a function name argument to avoid confusion with you use something like grains.get as function.

  • Move mongodb.conf state to mongodb-base.

  • Port assigment: do it right!

  • mine.py patch instead of manage.

  • Check with mine_functions doesn't work in the pillars. Is not supported yet.

About

En example of orchestration with MongoDB

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 94.0%
  • Scheme 3.6%
  • Python 2.0%
  • Makefile 0.4%