Giuseppe Lavagetto has uploaded a new change for review. (
https://gerrit.wikimedia.org/r/327164 )
Change subject: role::mediawiki::webserver: add hack to allow installing nginx
......................................................................
role::mediawiki::webserver: add hack to allow installing nginx
Without this, nginx cannot start when first installed, making puppet
fail.
Bug: T153042
Change-Id: I0374e27c50e50c465b18e20c7a14799b8ee7f918
---
M modules/role/manifests/mediawiki/webserver.pp
1 file changed, 15 insertions(+), 0 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/operations/puppet
refs/changes/64/327164/1
diff --git a/modules/role/manifests/mediawiki/webserver.pp
b/modules/role/manifests/mediawiki/webserver.pp
index 96cebe7..bcb0165 100644
--- a/modules/role/manifests/mediawiki/webserver.pp
+++ b/modules/role/manifests/mediawiki/webserver.pp
@@ -76,6 +76,21 @@
$pooldata = pick($::lvs::configuration::lvs_services[$pool], {})
$certs = [pick($pooldata['icinga']['sites'][$::site]['hostname'],
$::fqdn)]
}
+
+ # Given nginx will be installed on a system where apache is already
+ # running, the postinst script will fail to start it with the default
+ # configuration as port 80 is already in use. This is considered
working
+ # as designed by Debian, see
+ # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=754407
+ # However, we need the installation to complete correctly for puppet to
+ # work as expected, hence we pre-install a configuration that will make
+ # that possible. Note this file will be overwritten by puppet when
+ # the nginx configuration gets installed properly.
+ exec { 'Dummy nginx.conf for installation':
+ command => '/bin/mkdir -p /etc/nginx && /bin/echo -e "events {
worker_connections 1; }\nhttp{ server{ listen 90; }}\n" >
/etc/nginx/nginx.conf',
+ creates => '/etc/nginx/nginx.conf',
+ before => Package['nginx-full'],
+ }
tlsproxy::localssl { 'unified':
server_name => 'www.wikimedia.org',
certs => $certs,
--
To view, visit https://gerrit.wikimedia.org/r/327164
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I0374e27c50e50c465b18e20c7a14799b8ee7f918
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Giuseppe Lavagetto <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits