Commit 361ab63f authored by mh's avatar mh
Browse files

moved /dist/-stuff to /files/, heavily refactored a lot, made it more look all...

moved /dist/-stuff to /files/, heavily refactored a lot, made it more look all the same way. some sources added here and there. hope it still works everything, the location on the disk of /files/ is still call dists. no need to hurry to change that
parent 69df2afb
...@@ -5,32 +5,29 @@ ...@@ -5,32 +5,29 @@
# modules_dir { "imapproxy": } # modules_dir { "imapproxy": }
class imapproxy { class imapproxy {
$modulename = "imapproxy" case $operatingsystem {
$pkgname = "up-imapproxy" gentoo: { include imapproxy::gentoo }
$gentoocat = "net-mail" default: { include imapproxy::base }
$cnfname = "imapproxy.conf" }
$cnfpath = "/etc" }
class impapproxy::base {
package { $pkgname: package { up-imapproxy:
ensure => present, ensure => present,
category => $operatingsystem ? {
gentoo => $gentoocat,
default => '',
}
} }
file{ file{
"${cnfpath}/${cnfname}": "/etc/imapproxy.conf":
source => [ source => [
"puppet://$server/dist/${modulename}/${fqdn}/${cnfname}", "puppet://$server/files/imapproxy/${fqdn}/imapproxy.conf",
"puppet://$server/${modulename}/${fqdn}/${cnfname}", "puppet://$server/files/imapproxy/imapproxy.conf",
"puppet://$server/${modulename}/${cnfname}" "puppet://$server/imapproxy/imapproxy.conf"
], ],
owner => root, owner => root,
group => 0, group => 0,
mode => 0444, mode => 0444,
require => Package[$pkgname], require => Package[up-imapproxy],
notify => Service[imapproxy], notify => Service[imapproxy],
} }
...@@ -41,6 +38,10 @@ class imapproxy { ...@@ -41,6 +38,10 @@ class imapproxy {
hasstatus => true, hasstatus => true,
hasrestart => true, hasrestart => true,
} }
}
class imapproxy::gentoo inherits imapproxy::base {
Package[up-imapproxy]{
category => 'net-mail',
}
} }
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment