***SPAM*** [OpenSRF-GIT] OpenSRF branch master updated. 5e2221e546cd55e884b2984966aa9dc3468f63c7

Evergreen Git git at git.evergreen-ils.org
Wed Nov 5 11:45:47 EST 2014


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "OpenSRF".

The branch, master has been updated
       via  5e2221e546cd55e884b2984966aa9dc3468f63c7 (commit)
       via  8fb8d3b03cea233e15551614171ee3706c89ca69 (commit)
       via  21a3402ef02fd127e59354af44b5d3715d02a220 (commit)
       via  4712263d4fa3bd658e4d5e967a777910e1a00ec7 (commit)
       via  5f56ccb01c551046bc85d0e755db320ac1987cb3 (commit)
       via  1d4dce147af9f8273f3bcb86e7bd02fc04bcf70a (commit)
       via  08427f6a825b8e6ff277d8f9e94dbe326a210437 (commit)
      from  e8f78636586aeca15632bcfbf0cae20beb2d66a6 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 5e2221e546cd55e884b2984966aa9dc3468f63c7
Author: Ben Shum <bshum at biblio.org>
Date:   Fri Oct 31 23:53:58 2014 -0400

    LP#1369169: Remove hardcoded paths for OpenSRF directory
    
    Signed-off-by: Ben Shum <bshum at biblio.org>
    Signed-off-by: Bill Erickson <berickxx at gmail.com>

diff --git a/README b/README
index 8631eb0..38aff45 100644
--- a/README
+++ b/README
@@ -386,13 +386,13 @@ a2dismod websocket
 .(Debian / Ubuntu Precise)
 [source,bash]
 ---------------------------------------------------------------------------
-cp /home/opensrf/OpenSRF/examples/apache2/websockets/apache2.conf /etc/apache2-websockets/
+cp examples/apache2/websockets/apache2.conf /etc/apache2-websockets/
 ---------------------------------------------------------------------------
 +
 .(Ubuntu Trusty)
 [source,bash]
 ---------------------------------------------------------------------------
-cp /home/opensrf/OpenSRF/examples/apache_24/websockets/apache2.conf /etc/apache2-websockets/
+cp examples/apache_24/websockets/apache2.conf /etc/apache2-websockets/
 ---------------------------------------------------------------------------
 +
 6. OPTIONAL: add these configuration variables to /etc/apache2-websockets/envvars

commit 8fb8d3b03cea233e15551614171ee3706c89ca69
Author: Ben Shum <bshum at biblio.org>
Date:   Sat Sep 13 18:23:46 2014 -0400

    LP#1369169: Mention the requirement for valid SSL certificate
    
    The apache2-websockets instance will not start without a valid SSL certificate
    in /etc/apache2/ssl.  Include a mention of this in the README with the extra
    stipulation that it is still possible to use a self-signed SSL certificate for
    testing purposes, but this is not recommended for live installations.
    
    Signed-off-by: Ben Shum <bshum at biblio.org>
    Signed-off-by: Bill Erickson <berickxx at gmail.com>

diff --git a/README b/README
index 4159dfa..8631eb0 100644
--- a/README
+++ b/README
@@ -419,7 +419,13 @@ export OSRF_WEBSOCKET_MAX_REQUEST_WAIT_TIME=600
     died on the server, and thus no response was ever delivered to the gateway.
   * CONFIG_FILE / CTXT are the standard opensrf core config options.
 
-7. After OpenSRF is up and running (or after any re-install),
+7. Before you can start websockets, you must install a valid SSL certificate 
+   in `/etc/apache2/ssl/`.  It is possible, but not recommended, to generate a 
+   self-signed SSL certificate.  For example, if you need to test with a self-signed 
+   certicate on Chrome or Chromimum browsers, one workaround is to start the browser 
+   with `--ignore-certificate-errors`.
+
+8. After OpenSRF is up and running (or after any re-install),
    fire up the secondary Apache instance. Errors will appear in
    `/var/log/apache2-websockets/error.log`. Start apache2-websockets with:
 +

commit 21a3402ef02fd127e59354af44b5d3715d02a220
Author: Ben Shum <bshum at biblio.org>
Date:   Fri Sep 12 17:58:11 2014 -0400

    LP#1369169: Add websockets section to the OpenSRF README
    
    Remove the separate README.websockets and move the contents into the primary
    OpenSRF README document so that all steps are in one place.
    
    Additional edits to the websockets instructions to detail differences made
    between Ubuntu 14.04 Trusty and Debian / Ubuntu 12.04 Precise. More edits
    may be necessary for Debian Jessie later?
    
    Also, create a separate config file for Apache 2.4 that is copied into place
    for Ubuntu Trusty and potentially other systems that will need it.
    
    Signed-off-by: Ben Shum <bshum at biblio.org>
    Signed-off-by: Bill Erickson <berickxx at gmail.com>

diff --git a/README b/README
index 3b2532f..4159dfa 100644
--- a/README
+++ b/README
@@ -335,6 +335,99 @@ srfsh# request opensrf.math add 2,2
 +
 You should receive the value `4`.
 
+Optional: Websockets installation instructions
+----------------------------------------------
+Websockets are new to OpenSRF 2.4+ and are required for operating the new web-based
+staff client for Evergreen.  Complete the following steps as the *root* Linux 
+account:
+
+1. Install git if not already present:
++
+[source,bash]
+---------------------------------------------------------------------------
+apt-get install git-core
+---------------------------------------------------------------------------
++
+2. Install the apache-websocket module:
++
+[source,bash]
+---------------------------------------------------------------------------
+# Use a temporary directory
+cd /tmp
+git clone https://github.com/disconnect/apache-websocket
+cd apache-websocket
+apxs2 -i -a -c mod_websocket.c
+---------------------------------------------------------------------------
++
+3. Create the websocket Apache instance (more information about this in 
+   /usr/share/doc/apache2/README.multiple-instances)
++
+.(Debian / Ubuntu Precise)
+[source,bash]
+---------------------------------------------------------------------------
+sh /usr/share/doc/apache2.2-common/examples/setup-instance websockets
+---------------------------------------------------------------------------
++
+.(Ubuntu Trusty)
+[source,bash]
+---------------------------------------------------------------------------
+sh /usr/share/doc/apache2/examples/setup-instance websockets
+---------------------------------------------------------------------------
++
+4. Remove from the main apache instance
++
+[source,bash]
+---------------------------------------------------------------------------
+a2dismod websocket
+---------------------------------------------------------------------------
++
+5. Copy into place the config files
++
+.(Debian / Ubuntu Precise)
+[source,bash]
+---------------------------------------------------------------------------
+cp /home/opensrf/OpenSRF/examples/apache2/websockets/apache2.conf /etc/apache2-websockets/
+---------------------------------------------------------------------------
++
+.(Ubuntu Trusty)
+[source,bash]
+---------------------------------------------------------------------------
+cp /home/opensrf/OpenSRF/examples/apache_24/websockets/apache2.conf /etc/apache2-websockets/
+---------------------------------------------------------------------------
++
+6. OPTIONAL: add these configuration variables to /etc/apache2-websockets/envvars
+   and adjust as needed.
++
+---------------------------------------------------------------------------
+export OSRF_WEBSOCKET_IDLE_TIMEOUT=120
+export OSRF_WEBSOCKET_IDLE_CHECK_INTERVAL=5
+export OSRF_WEBSOCKET_CONFIG_FILE=/openils/conf/opensrf_core.xml
+export OSRF_WEBSOCKET_CONFIG_CTXT=gateway
+export OSRF_WEBSOCKET_MAX_REQUEST_WAIT_TIME=600
+---------------------------------------------------------------------------
++
+  * IDLE_TIMEOUT specifies how long we will allow a client to stay connected
+    while idle.  A longer timeout means less network traffic (from fewer
+    websocket CONNECT calls), but it also means more Apache processes are
+    tied up doing nothing.
+  * IDLE_CHECK_INTERVAL specifies how often we wake to check the idle status
+    of the connected client.
+  * MAX_REQUEST_WAIT_TIME is the maximum amount of time the gateway will
+    wait before declaring a client as idle when there is a long-running
+    outstanding request, yet no other activity is occurring.  This is
+    primarily a fail-safe to allow idle timeouts when one or more requests
+    died on the server, and thus no response was ever delivered to the gateway.
+  * CONFIG_FILE / CTXT are the standard opensrf core config options.
+
+7. After OpenSRF is up and running (or after any re-install),
+   fire up the secondary Apache instance. Errors will appear in
+   `/var/log/apache2-websockets/error.log`. Start apache2-websockets with:
++
+[source,bash]
+---------------------------------------------------------------------------
+/etc/init.d/apache2-websockets start
+---------------------------------------------------------------------------
+
 Troubleshooting note for Python users
 -------------------------------------
 
diff --git a/README.websockets b/README.websockets
deleted file mode 100644
index 15f38b1..0000000
--- a/README.websockets
+++ /dev/null
@@ -1,53 +0,0 @@
-Websockets installation instructions for Debian
-
-# TODO: Most of this can be scripted.
-
-# ! as root !
-# Perform these steps after installing OpenSRF.
-
-# install the apache-websocket module
-% cd tmp # or wherever
-% git clone https://github.com/disconnect/apache-websocket
-% cd apache-websocket
-% apxs2 -i -a -c mod_websocket.c
-
-# create the websocket Apache instance
-# see also /usr/share/doc/apache2/README.multiple-instances
-% sh /usr/share/doc/apache2.2-common/examples/setup-instance websockets
-
-# remove from the main apache instance
-% a2dismod websocket
-
-# update configs
-% cp /path/to/OpenSRF/examples/apache2/websockets/apache2.conf /etc/apache2-websockets/
-
-# OPTIONAL: add these configuration variables to
-# /etc/apache2-websockets/envvars and adjust as needed.
-# export OSRF_WEBSOCKET_IDLE_TIMEOUT=120
-# export OSRF_WEBSOCKET_IDLE_CHECK_INTERVAL=5
-# export OSRF_WEBSOCKET_CONFIG_FILE=/openils/conf/opensrf_core.xml
-# export OSRF_WEBSOCKET_CONFIG_CTXT=gateway
-# export OSRF_WEBSOCKET_MAX_REQUEST_WAIT_TIME=600
-#
-# IDLE_TIMEOUT specifies how long we will allow a client to stay connected
-# while idle.  A longer timeout means less network traffic (from fewer
-# websocket CONNECT calls), but it also means more Apache processes are
-# tied up doing nothing.
-#
-# IDLE_CHECK_INTERVAL specifies how often we wake to check the idle status
-# of the connected client.
-#
-# MAX_REQUEST_WAIT_TIME is the maximum amount of time the gateway will
-# wait before declaring a client as idle when there is a long-running
-# outstanding request, yet no other activity is occurring.  This is
-# primarily a fail-safe to allow idle timeouts when one or more requests
-# died on the server, and thus no response was ever delivered to the gateway.
-#
-# Both specified in seconds
-#
-# CONFIG_FILE / CTXT are the standard opensrf core config options.
-
-# After OpenSRF is up and running (or after any re-install),
-# fire up the secondary Apache instance. Errors will appear in
-# /var/log/apache2-websockets/error.log
-% /etc/init.d/apache2-websockets start

commit 4712263d4fa3bd658e4d5e967a777910e1a00ec7
Author: Ben Shum <bshum at biblio.org>
Date:   Sat Sep 13 18:04:54 2014 -0400

    LP#1369169: Add Apache 2.4 specific configuration file for websockets
    
    For Apache 2.4, there were some necessary modifications for running the
    websockets code properly. Similar to how we do things in Evergreen, we
    added a new directory for apache_24 which contains the modified apache2.conf
    file.
    
    Signed-off-by: Ben Shum <bshum at biblio.org>
    Signed-off-by: Bill Erickson <berickxx at gmail.com>

diff --git a/examples/apache_24/websockets/apache2.conf b/examples/apache_24/websockets/apache2.conf
new file mode 100644
index 0000000..9076b5c
--- /dev/null
+++ b/examples/apache_24/websockets/apache2.conf
@@ -0,0 +1,80 @@
+# This is the main Apache 2.4 server configuration file for the OpenSRF
+# WebSockets gateway.
+
+Include mods-available/mpm_prefork.load
+Include mods-available/mpm_prefork.conf
+Include mods-available/access_compat.load
+Include mods-available/authz_core.load
+
+# if we don't want to run as "opensrf", change the LockFile
+#LockFile ${APACHE_LOCK_DIR}/accept.lock
+Mutex file:${APACHE_LOCK_DIR} default
+PidFile ${APACHE_PID_FILE}
+User ${APACHE_RUN_USER}
+Group ${APACHE_RUN_GROUP}
+
+DefaultType None
+HostnameLookups Off
+ErrorLog ${APACHE_LOG_DIR}/error.log
+LogLevel warn
+
+# only affects the initial connection, which should be quick.
+Timeout 30
+
+# WebSockets is KeepAlive on steroids
+KeepAlive Off
+
+<IfModule mpm_prefork_module>
+    StartServers          5
+    MinSpareServers       5
+    MaxSpareServers      20
+    # use ServerLimit to raise beyond 256
+    MaxClients          256
+    MaxRequestsPerChild   0
+</IfModule>
+
+# include the exact mods we need
+Include mods-available/mime.load
+Include mods-available/mime.conf
+# SSL requires mime
+Include mods-available/ssl.load
+Include mods-available/ssl.conf
+Include mods-available/socache_shmcb.load
+Include mods-available/websocket.load
+
+LogFormat "%v:%p %h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" vhost_combined
+LogFormat "%h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" combined
+LogFormat "%h %l %u %t \"%r\" %>s %O" common
+LogFormat "%{Referer}i -> %U" referer
+LogFormat "%{User-agent}i" agent
+
+# WebSockets via SSL
+Listen 7682
+NameVirtualHost *:7682
+<VirtualHost *:7682>
+    DocumentRoot /var/www
+    ServerName localhost:7682
+    ServerAlias 127.0.0.1:7682
+    SSLEngine on
+    SSLHonorCipherOrder On
+    SSLCipherSuite ECDHE-RSA-AES256-SHA384:AES256-SHA256:RC4:HIGH:!MD5:!aNULL:!EDH:!AESGCM
+
+    # re-use the certs from the main apache instance
+    SSLCertificateFile /etc/apache2/ssl/server.crt
+    SSLCertificateKeyFile /etc/apache2/ssl/server.key
+</VirtualHost>
+
+# WebSockets via non-SSL
+Listen 7680
+NameVirtualHost *:7680
+<VirtualHost *:7680>
+    ServerName localhost:7680
+    ServerAlias 127.0.0.1:7680
+    DocumentRoot /var/www
+</VirtualHost>
+                                                                                
+# OpenSRF WebSockets gateway
+<Location /osrf-websocket-translator>
+    SetHandler websocket-handler
+    WebSocketHandler /usr/lib/apache2/modules/osrf_websocket_translator.so osrf_websocket_init
+</Location>

commit 5f56ccb01c551046bc85d0e755db320ac1987cb3
Author: Ben Shum <bshum at biblio.org>
Date:   Sat Sep 13 18:07:47 2014 -0400

    LP#1369169: Remove trailing whitespace from apache2.conf
    
    For some reason, there was a lot of trailing whitespace in this apache2.conf
    file for websockets. Removing them.
    
    Signed-off-by: Ben Shum <bshum at biblio.org>
    Signed-off-by: Bill Erickson <berickxx at gmail.com>

diff --git a/examples/apache2/websockets/apache2.conf b/examples/apache2/websockets/apache2.conf
index 0aaca73..b04f3d7 100644
--- a/examples/apache2/websockets/apache2.conf
+++ b/examples/apache2/websockets/apache2.conf
@@ -1,5 +1,5 @@
 # This is the main Apache server configuration file for the OpenSRF
-# WebSockets gateway.  
+# WebSockets gateway.
 
 # if we don't want to run as "opensrf", change the LockFile
 LockFile ${APACHE_LOCK_DIR}/accept.lock
@@ -43,31 +43,31 @@ LogFormat "%{User-agent}i" agent
 
 # WebSockets via SSL
 Listen 7682
-NameVirtualHost *:7682                                                          
-<VirtualHost *:7682>                                                            
-    DocumentRoot /var/www                                                       
-    ServerName localhost:7682                                                   
-    ServerAlias 127.0.0.1:7682                                                  
-    SSLEngine on                                                                
-    SSLHonorCipherOrder On                                                      
+NameVirtualHost *:7682
+<VirtualHost *:7682>
+    DocumentRoot /var/www
+    ServerName localhost:7682
+    ServerAlias 127.0.0.1:7682
+    SSLEngine on
+    SSLHonorCipherOrder On
     SSLCipherSuite ECDHE-RSA-AES256-SHA384:AES256-SHA256:RC4:HIGH:!MD5:!aNULL:!EDH:!AESGCM
 
     # re-use the certs from the main apache instance
     SSLCertificateFile /etc/apache2/ssl/server.crt
     SSLCertificateKeyFile /etc/apache2/ssl/server.key
-</VirtualHost>                                                                  
-                                                                                
+</VirtualHost>
+
 # WebSockets via non-SSL
 Listen 7680
-NameVirtualHost *:7680                                                          
-<VirtualHost *:7680>                                                            
-    ServerName localhost:7680                                                   
-    ServerAlias 127.0.0.1:7680                                                  
-    DocumentRoot /var/www                                                       
-</VirtualHost>                                                                  
+NameVirtualHost *:7680
+<VirtualHost *:7680>
+    ServerName localhost:7680
+    ServerAlias 127.0.0.1:7680
+    DocumentRoot /var/www
+</VirtualHost>
                                                                                 
 # OpenSRF WebSockets gateway
-<Location /osrf-websocket-translator>                                           
-    SetHandler websocket-handler                                                
+<Location /osrf-websocket-translator>
+    SetHandler websocket-handler
     WebSocketHandler /usr/lib/apache2/modules/osrf_websocket_translator.so osrf_websocket_init
-</Location> 
+</Location>

commit 1d4dce147af9f8273f3bcb86e7bd02fc04bcf70a
Author: Ben Shum <bshum at biblio.org>
Date:   Sat Sep 13 17:03:19 2014 -0400

    LP#1369169: Standardize styling of root linux account for README
    
    Signed-off-by: Ben Shum <bshum at biblio.org>
    Signed-off-by: Bill Erickson <berickxx at gmail.com>

diff --git a/README b/README
index 0f84872..3b2532f 100644
--- a/README
+++ b/README
@@ -28,9 +28,9 @@ before you can successfully configure, compile, and install OpenSRF.
 On Debian and Ubuntu, the easiest way to install these prerequisites
 is to use the Makefile.install prerequisite installer.
 
-Issue the following commands as the root user to install prerequisites
-using the Makefile.install prerequisite installer, substituting your
-operating system identifier for <osname> below:
+Issue the following commands as the *root* Linux account to install 
+prerequisites using the Makefile.install prerequisite installer, substituting 
+your operating system identifier for <osname> below:
 
 ---------------------------------------------------------------------------
 apt-get install make

commit 08427f6a825b8e6ff277d8f9e94dbe326a210437
Author: Ben Shum <bshum at biblio.org>
Date:   Sat Sep 13 17:38:54 2014 -0400

    LP#1369169: Add generated README.html to the .gitignore file for OpenSRF
    
    Signed-off-by: Ben Shum <bshum at biblio.org>
    Signed-off-by: Bill Erickson <berickxx at gmail.com>

diff --git a/.gitignore b/.gitignore
index 99021f3..d614afe 100644
--- a/.gitignore
+++ b/.gitignore
@@ -21,6 +21,7 @@ ltmain.sh
 Makefile
 Makefile.in
 missing
+README.html
 src/c-apps/.deps/
 src/c-apps/.libs/
 src/c-apps/Makefile

-----------------------------------------------------------------------

Summary of changes:
 .gitignore                                         |    1 +
 README                                             |  105 +++++++++++++++++++-
 README.websockets                                  |   53 ----------
 examples/apache2/websockets/apache2.conf           |   38 ++++----
 .../{apache2 => apache_24}/websockets/apache2.conf |   49 +++++----
 5 files changed, 150 insertions(+), 96 deletions(-)
 delete mode 100644 README.websockets
 copy examples/{apache2 => apache_24}/websockets/apache2.conf (51%)


hooks/post-receive
-- 
OpenSRF


More information about the opensrf-commits mailing list