dev/provisioning/modules/apache/examples/vhost_ssl.pp
author Chloe Laisne <chloe.laisne@gmail.com>
Thu, 23 Jun 2016 10:41:57 +0200
changeset 198 541e26eb356f
parent 28 b0b56e0f8c7f
permissions -rw-r--r--
Display filter IDs Remove unused transitionTo/updateURL methods managed by filter service

## SSL-enabled vhosts
# SSL-enabled vhosts respond only to HTTPS queries.

# Base class. Turn off the default vhosts; we will be declaring
# all vhosts below.
class { 'apache':
  default_vhost => false,
}

# Non-ssl vhost
apache::vhost { 'first.example.com non-ssl':
  servername => 'first.example.com',
  port       => '80',
  docroot    => '/var/www/first',
}

# SSL vhost at the same domain
apache::vhost { 'first.example.com ssl':
  servername => 'first.example.com',
  port       => '443',
  docroot    => '/var/www/first',
  ssl        => true,
}