summaryrefslogtreecommitdiff
path: root/puppet
diff options
context:
space:
mode:
Diffstat (limited to 'puppet')
-rw-r--r--puppet/modules/leap/manifests/cli/install.pp16
-rw-r--r--puppet/modules/site_couchdb/manifests/create_dbs.pp11
2 files changed, 19 insertions, 8 deletions
diff --git a/puppet/modules/leap/manifests/cli/install.pp b/puppet/modules/leap/manifests/cli/install.pp
index 25e87033..d009316b 100644
--- a/puppet/modules/leap/manifests/cli/install.pp
+++ b/puppet/modules/leap/manifests/cli/install.pp
@@ -1,13 +1,20 @@
# installs leap_cli on node
class leap::cli::install ( $source = false ) {
+
+ # nokogiri is a dependency gem of leap_cli and
+ # needs build tools in order to get compiled
+ ensure_packages (['gcc', 'make', 'zlib1g-dev'])
+ class { '::ruby':
+ install_dev => true,
+ require => [ Package['gcc'], Package['make'], Package['zlib1g-dev'] ]
+ }
+
+
if $source {
# needed for building leap_cli from source
include ::git
include ::rubygems
- class { '::ruby':
- install_dev => true
- }
class { 'bundler::install': install_method => 'package' }
@@ -40,7 +47,8 @@ class leap::cli::install ( $source = false ) {
else {
package { 'leap_cli':
ensure => installed,
- provider => gem
+ provider => gem,
+ require => Class['ruby']
}
}
}
diff --git a/puppet/modules/site_couchdb/manifests/create_dbs.pp b/puppet/modules/site_couchdb/manifests/create_dbs.pp
index ddfb7d65..1c594bb6 100644
--- a/puppet/modules/site_couchdb/manifests/create_dbs.pp
+++ b/puppet/modules/site_couchdb/manifests/create_dbs.pp
@@ -1,5 +1,6 @@
# creates neccesary databases
class site_couchdb::create_dbs {
+ $services = hiera('services', [])
Class['site_couchdb::setup']
-> Class['site_couchdb::create_dbs']
@@ -42,10 +43,12 @@ class site_couchdb::create_dbs {
## shared database
## r/w: soledad
- couchdb::create_db { 'shared':
- members => "{ \"names\": [\"${site_couchdb::couchdb_soledad_user}\"], \"roles\": [\"replication\"] }",
- require => Couchdb::Query::Setup['localhost'],
- notify => Service['soledad-server'];
+ if member($services, 'soledad') {
+ couchdb::create_db { 'shared':
+ members => "{ \"names\": [\"${site_couchdb::couchdb_soledad_user}\"], \"roles\": [\"replication\"] }",
+ require => Couchdb::Query::Setup['localhost'],
+ notify => Service['soledad-server'];
+ }
}
## tickets database