-
Notifications
You must be signed in to change notification settings - Fork 0
Installation
Setting up your puppet master to use mongodb as an ENC with regard to this project is pretty easy. You will need a few python modules, you will need to edit a conf/conf.ini file, run a setup.py script, and finally change your puppet.conf to use the mongodb_node_classifier.py script.
- sudo pip install pymongo --upgrade (on Ubuntu 12.04 you can do sudo apt-get install python-pymongo)
- sudo pip install PyYAML
- sudo pip install argparse
- sudo pip install ConfigParser
-
Clone this git repo to /opt
-
cd /opt; git clone git@github.com:bcarpio/mongodb-enc.git
-
Edit the conf/conf.ini
-
mongodb_servers - This is going to a list of servers which are configured as a replica set
-
mongodb_db_name - This is going to be a mongodb database name which will be created by the mongodb-enc
-
mongodb_collection_name - This is going to be the mongodb collection which will be created by the mongod-benc
-
Run scripts/setup.py - This is going to create a node of "default" for you. By default all nodes created will inherit the "default" node's classes. The add_node.py script will inherit the node "default". Read the individual script documentation for more information.
-
Edit the /etc/puppet/puppet.conf file and add the following:
[master] node_terminus = exec external_nodes = /opt/mongodb-enc/scripts/mongodb_node_classifier.py
* Restart your puppetmaster process or apache if using Passenger