diff options
author | varac <varacanero@zeromail.org> | 2013-05-23 18:53:17 +0200 |
---|---|---|
committer | Micah Anderson <micah@riseup.net> | 2013-05-23 17:42:49 -0400 |
commit | 064195792e264a125b9bd75ff931552af054ecf9 (patch) | |
tree | ae91cbd02886a3bd1767e92000a0f1ca251887d5 | |
parent | ddb899b650e63c5557370fb7a3b2c3bfd14b1ce7 (diff) |
include site_couchdb::bigcouch::add_nodes in site_couchdb/manifests/init.pp
-rw-r--r-- | puppet/modules/site_couchdb/manifests/bigcouch/add_nodes.pp | 5 | ||||
-rw-r--r-- | puppet/modules/site_couchdb/manifests/init.pp | 9 |
2 files changed, 12 insertions, 2 deletions
diff --git a/puppet/modules/site_couchdb/manifests/bigcouch/add_nodes.pp b/puppet/modules/site_couchdb/manifests/bigcouch/add_nodes.pp new file mode 100644 index 00000000..241a4914 --- /dev/null +++ b/puppet/modules/site_couchdb/manifests/bigcouch/add_nodes.pp @@ -0,0 +1,5 @@ +class site_couchdb::bigcouch::add_nodes { + # loop through neighbors array and add nodes + $nodes = $::site_couchdb::bigcouch_config['neighbors'] + couchdb::bigcouch::add_node { $nodes: } +} diff --git a/puppet/modules/site_couchdb/manifests/init.pp b/puppet/modules/site_couchdb/manifests/init.pp index 9f4824b4..802f3224 100644 --- a/puppet/modules/site_couchdb/manifests/init.pp +++ b/puppet/modules/site_couchdb/manifests/init.pp @@ -33,9 +33,12 @@ class site_couchdb { bigcouch_cookie => $bigcouch_cookie, ednp_port => $ednp_port } - include couchdb::bigcouch::package::cloudant - Service ['couchdb'] + class { 'couchdb::bigcouch::package::cloudant': } + + Class ['couchdb::bigcouch::package::cloudant'] + -> Service ['couchdb'] + -> Class ['site_couchdb::bigcouch::add_nodes'] -> Couchdb::Create_db['users'] -> Couchdb::Create_db['tokens'] -> Couchdb::Add_user[$couchdb_webapp_user] @@ -47,6 +50,8 @@ class site_couchdb { ca => $ca } + class { 'site_couchdb::bigcouch::add_nodes': } + couchdb::query::setup { 'localhost': user => $couchdb_admin_user, pw => $couchdb_admin_pw, |