1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
# File 'manifests/package.pp', line 1
class mediawiki::package {
$phpmysql = $osfamily ? {
'redhat' => 'php-mysql',
'debian' => 'php5-mysql',
default => 'php-mysql',
}
package {$phpmysql:
ensure => present,
}
if $osfamily == 'redhat' {
package {['php-xml','git']:
ensure => present,
}
}
class {'::apache':
docroot => '/var/www/html',
mpm_module => prefork,
subscribe => Package[$phpmysql],
}
class {'::apache::mod::php':}
vcsrepo {'/var/www/html':
ensure => present,
provider => git,
source => "https://github.com/wikimedia/mediawiki.git",
revision => "REL1_23",
}
file {'/var/www/html/index.html':
ensure => absent,
}
File['/var/www/html/index.html'] -> Vcsrepo['/var/www/html']
class {'::mysql::server':
root_password => 'training',
}
class {'::firewall': }
firewall {'000 allow http access':
port => 80,
proto => tcp,
action => accept,
}
}
|