Hello,
I'm using the apache module to set up new http / https servers and I'm
having a problem.
I created a new class for the installation of a standard vhost for our
institute. I set the default_vhost option to false in the apache class.
The problem is that with this option set to false, it always deletes the
vhost that my class creates.
class apache::campus_default_vhost {
class { 'apache':
mpm_module => 'prefork',
default_vhost => false,
default_ssl_vhost => false,
}
apache::listen { '80': }
apache::listen { '443': }
include apache::mod::alias
include apache::mod::rewrite
include apache::vhosts
include apache::mod::vhost_alias
include apache::mod::ssl
if $::osfamily == 'Debian' {
file { '/etc/apache2/certs':
ensure => 'directory',
mode => '0755',
}
file { "/etc/apache2/sites-available/${servername}.conf":
ensure => present,
content => template('apache/vhost-deb.conf.erb'),
}
exec { "enable-${servername}-vhost":
command => "/usr/sbin/a2ensite ${servername}.conf ;
/etc/init.d/apache2 restart",
require => [
File["/etc/apache2/sites-available/${servername}.conf"] ],
unless => [
"/usr/bin/test -e
/etc/apache2/sites-enabled/${servername}.conf 2>/dev/null",
],
}
file { '/etc/apache2/certs/sertao.crt':
ensure => present,
content => template('apache/sertao.crt'),
}
file { '/etc/apache2/certs/sertao.key':
ensure => present,
content => template('apache/sertao.key'),
}
file { '/etc/apache2/certs/ca_join_icpedu.crt':
ensure => present,
content => template('apache/ca_join_icpedu.crt'),
}
} else {
notify {'Não funciona em sua distribuição!':}
}
}
Is this the normal operation of the class?
--
Elias Pereira
--
You received this message because you are subscribed to the Google Groups
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/puppet-users/CAHdxDAEz3AWAy9LkCowKEMzi9q3OLyDXHr5PCqnVWoU18vvNXA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.