aboutsummaryrefslogtreecommitdiffstats
path: root/modules/postfix/manifests
diff options
context:
space:
mode:
Diffstat (limited to 'modules/postfix/manifests')
-rw-r--r--modules/postfix/manifests/init.pp39
1 files changed, 39 insertions, 0 deletions
diff --git a/modules/postfix/manifests/init.pp b/modules/postfix/manifests/init.pp
new file mode 100644
index 00000000..7a1df0a0
--- /dev/null
+++ b/modules/postfix/manifests/init.pp
@@ -0,0 +1,39 @@
+class postfix {
+ # some trick to manage daemon directory, who is arch dependent on mdv
+ $usr_lib = $architecture ? {
+ x86_64 => "lib64",
+ default => "lib"
+ }
+
+ $path_daemon_directory = "/usr/$usr_lib/postfix/"
+
+
+ class postfix_base {
+ package { postfix:
+ ensure => installed
+ }
+
+ service { postfix:
+ ensure => running,
+ subscribe => [ Package['postfix']],
+ path => "/etc/init.d/postfix"
+ }
+ }
+
+ file { '/etc/postfix/main.cf':
+ ensure => present,
+ owner => root,
+ group => root,
+ mode => 644,
+ require => Package["postfix"],
+ content => "",
+ notify => [Service['postfix']]
+ }
+
+
+ class postfix_simple_relay inherits postfix_base {
+ file { '/etc/postfix/main.cf':
+ content => template("postfix/simple_relay_main.conf"),
+ }
+ }
+}