Page Contents

OMERO

Downloads
Feature List
Licensing

Previous topic

OMERO.web IIS deployment (Windows)

Next topic

OMERO.web Nginx and Gunicorn deployment (Unix/Linux)

This Page

Note

This documentation is for OMERO 5.2. This version is now in maintenance mode and will only be updated in the event of critical bugs or security concerns. OMERO 5.3 is expected in the first quarter of 2017.

DEPRECATED: OMERO.web Apache and mod_wsgi deployment (Unix/Linux)

Apache 2.2+ with mod_wsgi configuration (Unix/Linux)

Note

Since OMERO 5.2, the OMERO.web framework no longer bundles a copy of the Django package, instead manual installation of the Django dependency is required. It is highly recommended to use Django 1.8 (LTS) which requires Python 2.7. For more information see Python on the Version requirements page.

Also note that support for Apache deployment is deprecated as of OMERO 5.2.6 and is likely be dropped during the 5.3.x line.

OMERO.web uses the Web Server Gateway Interface (WSGI) as a primary deployment platform. The Python standard PEP 3333 that describes how a web server communicates with web applications.

Apache default configuration (Unix/Linux)

Install Django 1.8 using package requirements file:

$ pip install -r share/web/requirements-py27-apache.txt

Note

For more details refer to how to install Django 1.8 or hot to upgrade Django to 1.8.

Additional settings can be configured by changing the following properties:

Apache configuration (Unix/Linux)

If you have installed Apache, install mod_wsgi.

OMERO can automatically generate a configuration file for your web server. The location of the file will depend on your system, please refer to your web server’s manual. See Customizing your OMERO.web installation for additional customization options.

Set the following:

$ bin/omero config set omero.web.application_server "wsgi"

Creates symlinks for static media files

$ bin/omero web syncmedia

To create a site configuration file for inclusion in the main Apache configuration redirect the output of the following command into a file:

For Apache 2.4, run the following command:

$ bin/omero web config apache24 > httpd-omero.conf

For Apache 2.2, run the following command:

$ bin/omero web config apache > httpd-omero.conf

Configuration file:

<VirtualHost _default_:80>

  WSGIDaemonProcess omeroweb processes=5 threads=1 maximum-requests=0 display-name=%{GROUP} user=omero python-path=/usr/lib64/python2.6/site-packages/Ice:/home/omero/OMERO.server/lib/python:/home/omero/OMERO.server/lib/fallback:/home/omero/OMERO.server/lib/python/omeroweb

  WSGIScriptAlias / /home/omero/OMERO.server/lib/python/omeroweb/wsgi.py process-group=omeroweb

  <Directory "/home/omero/OMERO.server/lib/python/omeroweb">
    WSGIProcessGroup omeroweb
    WSGIApplicationGroup %{GLOBAL}
    Order allow,deny
    Allow from all
  </Directory>

  Alias /static /home/omero/OMERO.server/lib/python/omeroweb/static
  <Directory "/home/omero/OMERO.server/lib/python/omeroweb/static">
      Options -Indexes FollowSymLinks
      Order allow,deny
      Allow from all
  </Directory>

</VirtualHost>

# see https://code.google.com/p/modwsgi/wiki/ConfigurationIssues
WSGISocketPrefix run/wsgi
# Use this on Ubuntu/Debian/MacOSX systems:
# WSGISocketPrefix /var/run/wsgi

To configure an HTTPS server follow the Apache documentation.

Then reload Apache.

Running OMERO.web (Unix/Linux)

OMERO.web is used in ‘daemon’ mode where UNIX sockets are used to communicate between the Apache child processes and the daemon processes which are to handle a request. OMERO.web does not provide any management for these ‘daemon’ processes; bin/omero web start/status/stop will not work as they are for managing gunicorn processes only.