aboutsummaryrefslogtreecommitdiff
path: root/manifests
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2013-01-26 15:29:56 -0200
committerSilvio Rhatto <rhatto@riseup.net>2013-01-26 15:29:56 -0200
commit0cff2c8111f03221f041bf86684937efb8867fe4 (patch)
tree57a4a73592a2efec98b1745d1969802d80b8c5c1 /manifests
parentf24585f59eedc3159a3e566edd4828093b084f77 (diff)
downloadpuppet-nodo-0cff2c8111f03221f041bf86684937efb8867fe4.tar.gz
puppet-nodo-0cff2c8111f03221f041bf86684937efb8867fe4.tar.bz2
Make custom_key_dir a class parameter and not a global variable; misc database updates; adding default exec and fileserver config
Diffstat (limited to 'manifests')
-rw-r--r--manifests/init.pp7
-rw-r--r--manifests/nodo.pp3
-rw-r--r--manifests/subsystems/database.pp10
3 files changed, 14 insertions, 6 deletions
diff --git a/manifests/init.pp b/manifests/init.pp
index f5a3e66..14cdc9c 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -2,6 +2,13 @@
# Nodo module.
#
+# Default execution path
+Exec { path => "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" }
+
+# Fileserver backup
+filebucket { server: server => hiera('puppet::daemon::server', "puppet.${::domain}" }
+File { backup => server }
+
# Import required modules
import "common"
import "sshd"
diff --git a/manifests/nodo.pp b/manifests/nodo.pp
index af7251f..43d6d4f 100644
--- a/manifests/nodo.pp
+++ b/manifests/nodo.pp
@@ -60,8 +60,9 @@ class nodo {
# Apt configuration
if $use_apt != false {
class { 'apt':
- include_src => hiera('nodo::apt_include_src', false),
+ include_src => hiera('nodo::apt_include_src', false),
use_next_release => hiera('nodo::apt_use_next_release', false),
+ custom_key_dir => hiera('nodo::apt_custom_key_dir', 'puppet:///modules/site_apt/keys.d')
}
include apt::unattended_upgrades
diff --git a/manifests/subsystems/database.pp b/manifests/subsystems/database.pp
index d9e379c..5796e9c 100644
--- a/manifests/subsystems/database.pp
+++ b/manifests/subsystems/database.pp
@@ -31,21 +31,21 @@ class database {
define instance($password, $ensure = 'present', $privileges = all) {
include mysql::server
- mysql_database { "$name":
+ mysql_database { "${name}":
ensure => $ensure,
require => Service['mysql'],
}
- mysql_user { "$name@%":
+ mysql_user { "${name}@%":
ensure => $ensure,
password_hash => mysql_password($password),
- require => Mysql_database["$name"],
+ require => Mysql_database["${name}"],
}
if $ensure == 'present' {
- mysql_grant { "$name@%/$name":
+ mysql_grant { "${name}@%/${name}":
privileges => $privileges,
- require => Mysql_user["$name@%"],
+ require => Mysql_user["${name}@%"],
}
}
}