aboutsummaryrefslogtreecommitdiffstats
path: root/deployment/websites/manifests/init.pp
diff options
context:
space:
mode:
authorMichael Scherer <misc@mageia.org>2011-07-08 13:45:36 +0000
committerMichael Scherer <misc@mageia.org>2011-07-08 13:45:36 +0000
commit5a0dd9584067ef38fb718ce377ab3263a2820a17 (patch)
tree35f6cfe1014215adb855422529c5179151032f90 /deployment/websites/manifests/init.pp
parentb2bed550b44948c69792f7a53e9c96152d0cca6e (diff)
downloadpuppet-5a0dd9584067ef38fb718ce377ab3263a2820a17.tar
puppet-5a0dd9584067ef38fb718ce377ab3263a2820a17.tar.gz
puppet-5a0dd9584067ef38fb718ce377ab3263a2820a17.tar.bz2
puppet-5a0dd9584067ef38fb718ce377ab3263a2820a17.tar.xz
puppet-5a0dd9584067ef38fb718ce377ab3263a2820a17.zip
classe for pkgcpan, asked by jq ( requires a backport before being deployed )
Diffstat (limited to 'deployment/websites/manifests/init.pp')
-rw-r--r--deployment/websites/manifests/init.pp24
1 files changed, 24 insertions, 0 deletions
diff --git a/deployment/websites/manifests/init.pp b/deployment/websites/manifests/init.pp
index 790ec704..d62aef56 100644
--- a/deployment/websites/manifests/init.pp
+++ b/deployment/websites/manifests/init.pp
@@ -80,4 +80,28 @@ class websites {
url => "http://$web_domain/",
}
}
+
+ class pkgcpan inherits base {
+ $vhost = "pkgcpan.$domain"
+ $vhostdir = "$webdatadir/$vhost"
+
+ apache::vhost_base { "$vhost":
+ location => $vhostdir,
+ options => [ "Indexes" ]
+ }
+
+ file { $vhostdir:
+ ensure => directory,
+ }
+
+ package { "perl-Module-Packaged-Generator":
+ ensure => installed,
+ }
+
+ cron { "update cpanpkg":
+ hour => 23,
+ require => Package['perl-Module-Packaged-Generator'],
+ command => "pkgcpan -q -f $vhostdir/cpan_Mageia.db -d Mageia",
+ }
+ }
}