diff --git a/modules/etherpad_lite/manifests/apache.pp b/modules/etherpad_lite/manifests/apache.pp index f4817db537..869b0fec4f 100644 --- a/modules/etherpad_lite/manifests/apache.pp +++ b/modules/etherpad_lite/manifests/apache.pp @@ -7,10 +7,10 @@ class etherpad_lite::apache ( include remove_nginx apache::vhost { $vhost_name: - post => 443, + port => 443, docroot => 'MEANINGLESS ARGUMENT', priority => '50', - template => 'etherpadlite/etherpadlite.vhost.erb', + template => 'etherpad_lite/etherpadlite.vhost.erb', require => File["/etc/ssl/certs/${vhost_name}.pem", "/etc/ssl/private/${vhost_name}.key"], ssl => true, @@ -37,22 +37,22 @@ class etherpad_lite::apache ( mode => 0700, } - file { "/etc/ssl/cert/${vhost_name}.pem": + file { "/etc/ssl/certs/${vhost_name}.pem": ensure => present, replace => true, owner => 'root', mode => 0600, content => template('etherpad_lite/eplite.crt.erb'), - require => Apache::Vhost[$vhost_name], + require => File['/etc/ssl/certs'], } - file { '/etc/ssl/private/${vhost_name}.key': + file { "/etc/ssl/private/${vhost_name}.key": ensure => present, replace => true, owner => 'root', mode => 0600, content => template('etherpad_lite/eplite.key.erb'), - require => Apache::Vhost[$vhost_name], + require => File['/etc/ssl/private'], } } diff --git a/modules/etherpad_lite/templates/etherpadlite.vhost.erb b/modules/etherpad_lite/templates/etherpadlite.vhost.erb index 64cb28963a..6ac0aecd5f 100644 --- a/modules/etherpad_lite/templates/etherpadlite.vhost.erb +++ b/modules/etherpad_lite/templates/etherpadlite.vhost.erb @@ -1,31 +1,31 @@ -:80> - ServerAdmin <%= scope.lookupvar("etherpad_lite::serveradmin") %> +:80> + ServerAdmin <%= scope.lookupvar("etherpad_lite::apache::serveradmin") %> - ErrorLog ${APACHE_LOG_DIR}/<%= scope.lookupvar("etherpad_lite::vhost_name") %>-error.log + ErrorLog ${APACHE_LOG_DIR}/<%= scope.lookupvar("etherpad_lite::apache::vhost_name") %>-error.log LogLevel warn - CustomLog ${APACHE_LOG_DIR}/<%= scope.lookupvar("etherpad_lite::vhost_name") %>-access.log combined + CustomLog ${APACHE_LOG_DIR}/<%= scope.lookupvar("etherpad_lite::apache::vhost_name") %>-access.log combined - Redirect / https://<%= scope.lookupvar("etherpad_lite::vhost_name") %>/ + Redirect / https://<%= scope.lookupvar("etherpad_lite::apache::vhost_name") %>/ -:443> - ServerName <%= scope.lookupvar("etherpad_lite::vhost_name") %> - ServerAdmin <%= scope.lookupvar("etherpad_lite::serveradmin") %> +:443> + ServerName <%= scope.lookupvar("etherpad_lite::apache::vhost_name") %> + ServerAdmin <%= scope.lookupvar("etherpad_lite::apache::serveradmin") %> - ErrorLog ${APACHE_LOG_DIR}/<%= scope.lookupvar("etherpad_lite::vhost_name") %>-ssl-error.log + ErrorLog ${APACHE_LOG_DIR}/<%= scope.lookupvar("etherpad_lite::apache::vhost_name") %>-ssl-error.log LogLevel warn - CustomLog ${APACHE_LOG_DIR}/<%= scope.lookupvar("etherpad_lite::vhost_name") %>-ssl-access.log combined + CustomLog ${APACHE_LOG_DIR}/<%= scope.lookupvar("etherpad_lite::apache::vhost_name") %>-ssl-access.log combined SSLEngine on - SSLCertificateFile /etc/ssl/certs/<%= scope.lookupvar("etherpad_lite::vhost_name") %>.pem - SSLCertificateKeyFile /etc/ssl/private/<%= scope.lookupvar("etherpad_lite::vhost_name") %>.key + SSLCertificateFile /etc/ssl/certs/<%= scope.lookupvar("etherpad_lite::apache::vhost_name") %>.pem + SSLCertificateKeyFile /etc/ssl/private/<%= scope.lookupvar("etherpad_lite::apache::vhost_name") %>.key BrowserMatch "MSIE [2-6]" \ nokeepalive ssl-unclean-shutdown \ @@ -34,8 +34,8 @@ BrowserMatch "MSIE [17-9]" ssl-unclean-shutdown RewriteEngine on - RewriteCond %{HTTP_HOST} !<%= scope.lookupvar("etherpad_lite::vhost_name") %> - RewriteRule ^.*$ https://<%= scope.lookupvar("etherpad_lite::vhost_name") %> + RewriteCond %{HTTP_HOST} !<%= scope.lookupvar("etherpad_lite::apache::vhost_name") %> + RewriteRule ^.*$ https://<%= scope.lookupvar("etherpad_lite::apache::vhost_name") %> RewriteRule ^/(.*)$ http://localhost:9001/$1 [P] ProxyPassReverse / http://localhost:9001/ diff --git a/modules/jenkins_master/templates/jenkins.vhost.erb b/modules/jenkins_master/templates/jenkins.vhost.erb index 6d7612705a..a82d0672ea 100644 --- a/modules/jenkins_master/templates/jenkins.vhost.erb +++ b/modules/jenkins_master/templates/jenkins.vhost.erb @@ -1,32 +1,32 @@ -:80> - ServerAdmin <%= scope.lookupvar("jenkins::serveradmin") %> +:80> + ServerAdmin <%= scope.lookupvar("jenkins_master::serveradmin") %> - ErrorLog ${APACHE_LOG_DIR}/jenkins-error.log + ErrorLog ${APACHE_LOG_DIR}/jenkins_master-error.log LogLevel warn - CustomLog ${APACHE_LOG_DIR}/jenkins-access.log combined + CustomLog ${APACHE_LOG_DIR}/jenkins_master-access.log combined - Redirect / https://<%= scope.lookupvar("jenkins::vhost_name") %>/ + Redirect / https://<%= scope.lookupvar("jenkins_master::vhost_name") %>/ -:443> - ServerName <%= scope.lookupvar("jenkins::vhost_name") %> - ServerAdmin <%= scope.lookupvar("jenkins::serveradmin") %> +:443> + ServerName <%= scope.lookupvar("jenkins_master::vhost_name") %> + ServerAdmin <%= scope.lookupvar("jenkins_master::serveradmin") %> - ErrorLog ${APACHE_LOG_DIR}/jenkins-ssl-error.log + ErrorLog ${APACHE_LOG_DIR}/jenkins_master-ssl-error.log LogLevel warn - CustomLog ${APACHE_LOG_DIR}/jenkins-ssl-access.log combined + CustomLog ${APACHE_LOG_DIR}/jenkins_master-ssl-access.log combined SSLEngine on - SSLCertificateFile <%= scope.lookupvar("jenkins::ssl_cert_file") %> - SSLCertificateKeyFile <%= scope.lookupvar("jenkins::ssl_key_file") %> - <% if scope.lookupvar("jenkins::ssl_chain_file") != "" %> - SSLCertificateChainFile <%= scope.lookupvar("jenkins::ssl_chain_file") %> + SSLCertificateFile <%= scope.lookupvar("jenkins_master::ssl_cert_file") %> + SSLCertificateKeyFile <%= scope.lookupvar("jenkins_master::ssl_key_file") %> + <% if scope.lookupvar("jenkins_master::ssl_chain_file") != "" %> + SSLCertificateChainFile <%= scope.lookupvar("jenkins_master::ssl_chain_file") %> <% end %> BrowserMatch "MSIE [2-6]" \ @@ -36,8 +36,8 @@ BrowserMatch "MSIE [17-9]" ssl-unclean-shutdown RewriteEngine on - RewriteCond %{HTTP_HOST} !<%= scope.lookupvar("jenkins::vhost_name") %> - RewriteRule ^.*$ https://<%= scope.lookupvar("jenkins::vhost_name") %>/ + RewriteCond %{HTTP_HOST} !<%= scope.lookupvar("jenkins_master::vhost_name") %> + RewriteRule ^.*$ https://<%= scope.lookupvar("jenkins_master::vhost_name") %>/ RewriteRule /zuul/status http://127.0.0.1:8001/status [P] diff --git a/modules/lodgeit/manifests/init.pp b/modules/lodgeit/manifests/init.pp index bfe9d20b86..a69a1af220 100644 --- a/modules/lodgeit/manifests/init.pp +++ b/modules/lodgeit/manifests/init.pp @@ -35,11 +35,6 @@ class lodgeit { hasrestart => true } - service { "nginx": - ensure => running, - hasrestart => true - } - vcsrepo { "/tmp/lodgeit-main": ensure => latest, provider => git, diff --git a/modules/mailman/templates/mm_cfg.py.erb b/modules/mailman/templates/mm_cfg.py.erb index 67efe63a0b..08202a9647 100644 --- a/modules/mailman/templates/mm_cfg.py.erb +++ b/modules/mailman/templates/mm_cfg.py.erb @@ -63,10 +63,10 @@ IMAGE_LOGOS = '/images/mailman/' #------------------------------------------------------------- # Default domain for email addresses of newly created MLs -DEFAULT_EMAIL_HOST = '<%= mailman_host %>' +DEFAULT_EMAIL_HOST = '<%= vhost_name %>' #------------------------------------------------------------- # Default host for web interface of newly created MLs -DEFAULT_URL_HOST = '<%= mailman_host %>' +DEFAULT_URL_HOST = '<%= vhost_name %>' #------------------------------------------------------------- # Required when setting any of its arguments. add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST) diff --git a/modules/meetbot/manifests/init.pp b/modules/meetbot/manifests/init.pp index de3fdf99b5..c95ebc7031 100644 --- a/modules/meetbot/manifests/init.pp +++ b/modules/meetbot/manifests/init.pp @@ -20,15 +20,10 @@ class meetbot { ensure => present } - package { ['supybot', 'nginx', 'python-twisted']: + package { ['supybot', 'python-twisted']: ensure => present } - service { "nginx": - ensure => running, - hasrestart => true, - } - file { "/var/lib/meetbot": ensure => directory, owner => 'meetbot', diff --git a/modules/meetbot/templates/meetingLocalConfig.py.erb b/modules/meetbot/templates/meetingLocalConfig.py.erb index c2d5bbbeb0..b2af6ed388 100644 --- a/modules/meetbot/templates/meetingLocalConfig.py.erb +++ b/modules/meetbot/templates/meetingLocalConfig.py.erb @@ -1,4 +1,4 @@ class Config(object): # These two are **required**: logFileDir = '/var/lib/meetbot/<%= name %>/meetings/' - logUrlPrefix = 'http://<%= url %>/meetings/' + logUrlPrefix = 'http://<%= vhost_name %>/meetings/' diff --git a/modules/openstack_project/manifests/jenkins.pp b/modules/openstack_project/manifests/jenkins.pp index 4de417aa09..1dbc388265 100644 --- a/modules/openstack_project/manifests/jenkins.pp +++ b/modules/openstack_project/manifests/jenkins.pp @@ -5,7 +5,7 @@ class openstack_project::jenkins($jenkins_jobs_password) { } class { 'jenkins_master': - site => 'jenkins.openstack.org', + vhost_name => 'jenkins.openstack.org', serveradmin => 'webmaster@openstack.org', logo => 'openstack.png', ssl_cert_file => '/etc/ssl/certs/jenkins.openstack.org.pem', diff --git a/modules/openstack_project/manifests/lists.pp b/modules/openstack_project/manifests/lists.pp index 1c5c0ff087..70dcd692a7 100644 --- a/modules/openstack_project/manifests/lists.pp +++ b/modules/openstack_project/manifests/lists.pp @@ -12,7 +12,7 @@ class openstack_project::lists($listadmins) { } class { 'mailman': - mailman_host => 'lists.openstack.org' + vhost_name => 'lists.openstack.org' } realize (