summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames E. Blair <jeblair@hp.com>2015-09-02 10:13:28 -0700
committerJames E. Blair <jeblair@hp.com>2015-09-02 10:15:11 -0700
commit605ec41b304fc7f9be8e802f9e6d8e549d168fc4 (patch)
tree5243ec9bba9c545c3a65b939d201e2081db1f1a0
parent021bc83b283e091cc6dd73d96c849881dfe98e50 (diff)
Fix websocket configuration
Enable the proxy_websocket module. Correct the ProxyPass directives in use with websockets. The current versions result in 404 on socket.io.js because they strip the socket.io component of the path. Change-Id: I3505b4e9693602ec04baec2487871ce57a6dc7a6
Notes
Notes (review): Code-Review+2: Clark Boylan <cboylan@sapwetik.org> Code-Review+2: Jeremy Stanley <fungi@yuggoth.org> Workflow+1: Jeremy Stanley <fungi@yuggoth.org> Verified+2: Jenkins Submitted-by: Jenkins Submitted-at: Wed, 02 Sep 2015 18:42:31 +0000 Reviewed-on: https://review.openstack.org/219790 Project: openstack-infra/puppet-ethercalc Branch: refs/heads/master
-rw-r--r--manifests/apache.pp4
-rw-r--r--templates/etherpadlite.vhost.erb4
2 files changed, 6 insertions, 2 deletions
diff --git a/manifests/apache.pp b/manifests/apache.pp
index 9ff3b35..cc2dc45 100644
--- a/manifests/apache.pp
+++ b/manifests/apache.pp
@@ -58,6 +58,10 @@ class etherpad_lite::apache (
58 notify => Service['httpd'], 58 notify => Service['httpd'],
59 require => File['/etc/apache2/conf-available/connection-tuning'], 59 require => File['/etc/apache2/conf-available/connection-tuning'],
60 } 60 }
61
62 httpd_mod { 'proxy_wstunnel':
63 ensure => present,
64 }
61 } 65 }
62 66
63 file { $docroot: 67 file { $docroot:
diff --git a/templates/etherpadlite.vhost.erb b/templates/etherpadlite.vhost.erb
index fb92b3a..754a4ec 100644
--- a/templates/etherpadlite.vhost.erb
+++ b/templates/etherpadlite.vhost.erb
@@ -74,8 +74,8 @@
74 RewriteCond %{REQUEST_URI} ^/socket.io [NC] 74 RewriteCond %{REQUEST_URI} ^/socket.io [NC]
75 RewriteCond %{QUERY_STRING} transport=websocket [NC] 75 RewriteCond %{QUERY_STRING} transport=websocket [NC]
76 RewriteRule /(.*) ws://localhost:9001/$1 [P,L] 76 RewriteRule /(.*) ws://localhost:9001/$1 [P,L]
77 ProxyPass /socket.io http://localhost:9001 retry=0 77 ProxyPass /socket.io http://localhost:9001/socket.io retry=0
78 ProxyPassReverse /socket.io http://localhost:9001 78 ProxyPassReverse /socket.io http://localhost:9001/socket.io
79 </IfModule> 79 </IfModule>
80 80
81 ProxyPass / http://localhost:9001/ retry=0 81 ProxyPass / http://localhost:9001/ retry=0