summaryrefslogtreecommitdiff
path: root/puppet
diff options
context:
space:
mode:
authorvarac <varacanero@zeromail.org>2015-06-22 11:11:08 +0200
committervarac <varacanero@zeromail.org>2015-06-22 11:11:08 +0200
commit9e1a53d33e936507785d9a610d3b86956a2f1739 (patch)
tree8ec8bcd2340d7029613e4158d97d3c72582a5036 /puppet
parenta69732be70335ac3ca86b476d9a9679494904845 (diff)
parentdc2611f2fc2aab1c441d524862af30b349323c7c (diff)
Merge branch '6067_plain_couchdb' into develop
Diffstat (limited to 'puppet')
-rw-r--r--puppet/modules/site_couchdb/manifests/bigcouch.pp2
-rw-r--r--puppet/modules/site_couchdb/manifests/create_dbs.pp14
2 files changed, 9 insertions, 7 deletions
diff --git a/puppet/modules/site_couchdb/manifests/bigcouch.pp b/puppet/modules/site_couchdb/manifests/bigcouch.pp
index 82c85b52..469a2783 100644
--- a/puppet/modules/site_couchdb/manifests/bigcouch.pp
+++ b/puppet/modules/site_couchdb/manifests/bigcouch.pp
@@ -1,3 +1,4 @@
+# sets up bigcouch on couchdb node
class site_couchdb::bigcouch {
$config = $::site_couchdb::couchdb_config['bigcouch']
@@ -24,6 +25,7 @@ class site_couchdb::bigcouch {
-> Class['site_couchdb::setup']
-> Class['site_couchdb::bigcouch::add_nodes']
-> Class['site_couchdb::bigcouch::settle_cluster']
+ -> Class['site_couchdb::create_dbs']
include site_couchdb::bigcouch::add_nodes
include site_couchdb::bigcouch::settle_cluster
diff --git a/puppet/modules/site_couchdb/manifests/create_dbs.pp b/puppet/modules/site_couchdb/manifests/create_dbs.pp
index b743127a..eea4bbf5 100644
--- a/puppet/modules/site_couchdb/manifests/create_dbs.pp
+++ b/puppet/modules/site_couchdb/manifests/create_dbs.pp
@@ -1,13 +1,13 @@
+# creates neccesary databases
class site_couchdb::create_dbs {
Class['site_couchdb::setup']
- -> Class['site_couchdb::bigcouch::settle_cluster']
-> Class['site_couchdb::create_dbs']
### customer database
### r/w: webapp,
couchdb::create_db { 'customers':
- members => "{ \"names\": [\"$site_couchdb::couchdb_webapp_user\"], \"roles\": [\"replication\"] }",
+ members => "{ \"names\": [\"${site_couchdb::couchdb_webapp_user}\"], \"roles\": [\"replication\"] }",
require => Couchdb::Query::Setup['localhost']
}
@@ -30,27 +30,27 @@ class site_couchdb::create_dbs {
## r/w: webapp
$sessions_db = rotated_db_name('sessions', 'monthly')
couchdb::create_db { $sessions_db:
- members => "{ \"names\": [\"$site_couchdb::couchdb_webapp_user\"], \"roles\": [\"replication\"] }",
+ members => "{ \"names\": [\"${site_couchdb::couchdb_webapp_user}\"], \"roles\": [\"replication\"] }",
require => Couchdb::Query::Setup['localhost']
}
$sessions_next_db = rotated_db_name('sessions', 'monthly', 'next')
couchdb::create_db { $sessions_next_db:
- members => "{ \"names\": [\"$site_couchdb::couchdb_webapp_user\"], \"roles\": [\"replication\"] }",
+ members => "{ \"names\": [\"${site_couchdb::couchdb_webapp_user}\"], \"roles\": [\"replication\"] }",
require => Couchdb::Query::Setup['localhost']
}
## shared database
## r/w: soledad
couchdb::create_db { 'shared':
- members => "{ \"names\": [\"$site_couchdb::couchdb_soledad_user\"], \"roles\": [\"replication\"] }",
+ members => "{ \"names\": [\"${site_couchdb::couchdb_soledad_user}\"], \"roles\": [\"replication\"] }",
require => Couchdb::Query::Setup['localhost']
}
## tickets database
## r/w: webapp
couchdb::create_db { 'tickets':
- members => "{ \"names\": [\"$site_couchdb::couchdb_webapp_user\"], \"roles\": [\"replication\"] }",
+ members => "{ \"names\": [\"${site_couchdb::couchdb_webapp_user}\"], \"roles\": [\"replication\"] }",
require => Couchdb::Query::Setup['localhost']
}
@@ -87,7 +87,7 @@ class site_couchdb::create_dbs {
## store messages to the clients such as payment reminders
## r/w: webapp
couchdb::create_db { 'messages':
- members => "{ \"names\": [\"$site_couchdb::couchdb_webapp_user\"], \"roles\": [\"replication\"] }",
+ members => "{ \"names\": [\"${site_couchdb::couchdb_webapp_user}\"], \"roles\": [\"replication\"] }",
require => Couchdb::Query::Setup['localhost']
}
}