1 define front_vhost($source, $crt = undefined, $args = {}){
3 file{"/etc/ssl/private/$name.crt":
5 source => ["puppet:///modules/$crt.crt", 'puppet:///modules/gigi/gigi.crt'],
7 notify => Service['nginx'],
8 before => File["/etc/nginx/sites-available/$name.conf"]
10 file{"/etc/ssl/private/$name.key":
12 source => ["puppet:///modules/$crt.key", 'puppet:///modules/gigi/gigi.key'],
14 before => File["/etc/nginx/sites-available/$name.conf"]
17 file {"/etc/nginx/sites-available/$name.conf":
19 content => epp($source, $args),
20 require => Package['nginx-light'],
22 file {"/etc/nginx/sites-enabled/$name.conf":
24 target => "/etc/nginx/sites-available/$name.conf",
25 require => Package['nginx-light'],
26 notify => Service['nginx']
31 include container::contained;
32 include container::no_ssh;
33 apt_key{ 'E643C483A426BB5311D26520A631B6AF9FD3DF94':
34 source => 'http://deb2.dogcraft.de/signer.gpg',
37 file { '/etc/apt/sources.list.d/dogcraft.list':
38 source => 'puppet:///modules/lxc/dogcraft.list',
40 notify => Exec['apt_update']
42 package{ 'nginx-light':
45 $gigi_ip = $ips[gigi];
47 source => 'gigi/nginx',
49 notify => Service['nginx']
52 source => 'crl/nginx',
53 notify => Service['nginx']
55 package{'wpia-infradocs':
58 front_vhost{'infradocs':
59 source => 'infradocs/nginx',
60 notify => Service['nginx']
62 if($protected != 'no') {
63 file{'/etc/nginx/access.txt':
64 content => $protected,
65 require => Package['nginx-light'],
66 before => Service['nginx']
69 file{'/etc/ssl/root.crt':
71 source => ['puppet:///modules/nre/config/ca/root.crt'],
73 notify => Service['nginx'],
74 before => Front_vhost['quiz']
77 source => 'quiz/nginx',
79 notify => Service['nginx']
90 source => 'gitweb/nginx.epp',
91 notify => Service['nginx'],
95 Front_vhost <| tag == nginx |> ~> Service['nginx']
96 File <| tag == nginx |> ~> Service['nginx']