diff --git a/omero/autogen_omeroweb_install.sh b/omero/autogen_omeroweb_install.sh index fd6e644384..df79929905 100644 --- a/omero/autogen_omeroweb_install.sh +++ b/omero/autogen_omeroweb_install.sh @@ -13,7 +13,6 @@ export DOCVENV=${DOCVENV:-$WORKSPACE/.venv3} $DOCVENV/bin/pip install 'ansible<2.10' jinja2==3.0.1 -(cd $WORKSPACE/omeroweb-install && $DOCVENV/bin/ansible-playbook ./.travis/../ansible/omeroweb-install-doc.yml -i ./.travis/../ansible/hosts/centos7-ice3.6 --extra-vars '{"clean": True, "web_session": True}') (cd $WORKSPACE/omeroweb-install && $DOCVENV/bin/ansible-playbook ./.travis/../ansible/omeroweb-install-doc.yml -i ./.travis/../ansible/hosts/ubuntu2004-ice3.6 --extra-vars '{"clean": True, "web_session": True}') (cd $WORKSPACE/omeroweb-install && $DOCVENV/bin/ansible-playbook ./.travis/../ansible/omeroweb-install-doc.yml -i ./.travis/../ansible/hosts/ubuntu2204-ice3.6 --extra-vars '{"clean": True, "web_session": True}') (cd $WORKSPACE/omeroweb-install && $DOCVENV/bin/ansible-playbook ./.travis/../ansible/omeroweb-install-doc.yml -i ./.travis/../ansible/hosts/rockylinux9-ice3.6 --extra-vars '{"clean": True, "web_session": True}') diff --git a/omero/conf.py b/omero/conf.py index 34b1d03b8c..19d016c72c 100755 --- a/omero/conf.py +++ b/omero/conf.py @@ -373,7 +373,9 @@ def copy_legacy_redirects(app, exception): 'sysadmins/unix/server-ubuntu1804-ice36.html', 'sysadmins/unix/install-web/walkthrough/omeroweb-install-debian9-ice3.6.html', 'sysadmins/unix/server-debian9-ice36.html', + 'sysadmins/unix/install-web/walkthrough/omeroweb-install-centos7-ice3.6.html', 'sysadmins/unix/install-web/walkthrough/omeroweb-install-centos8-ice3.6.html', + 'sysadmins/unix/server-centos7-ice36.html', 'sysadmins/unix/server-centos8-ice36.html', 'sysadmins/server-overview.html', 'sysadmins/server-tables.html', diff --git a/omero/sysadmins/python3-migration.rst b/omero/sysadmins/python3-migration.rst index 74e2b39890..e2e60d98aa 100644 --- a/omero/sysadmins/python3-migration.rst +++ b/omero/sysadmins/python3-migration.rst @@ -20,20 +20,12 @@ Basic steps Choosing a platform ------------------- -The two recommended platforms, CentOS 7 and Ubuntu 18.04, have Python 3.6 as -default installation and have therefore received the most testing which is why -Python 3.6 is the preferred version of Python. +The two recommended platforms, Rocky Linux/RHEL 9 and Ubuntu 22.04, +have Python 3.9 and 3.10 respectively as +default installation. -Both Python 3.5 and 3.7 should work and are slated to have support added, but -Python 3.6 has been the focus of testing during the migration. +All Python 3.8+ versions should work. -Similarly, other operating systems are slated for having support added, but help -from the community would be very welcome! Obvious next candidates are CentOS 8 -and Ubuntu 20.04. - -Debian 9 is still on Python 3.5 and Debian 10 has moved to Ice 3.7. -We have nonetheless an installation guide for Debian 9 with Python 3.5 and Ice 3.6 -but an installation guide for Debian 10 with Python 3.7 and Ice 3.6. Other prerequisites ------------------- @@ -44,8 +36,8 @@ the current choices are: - Ice 3.6 (non-optional) - Java 11 -- Nginx 1.14 or higher -- PostgreSQL 11 +- Nginx 1.24 or higher +- PostgreSQL 13+ Other options ------------- diff --git a/omero/sysadmins/unix/install-web/walkthrough/omeroweb-install-centos7-ice3.6.html b/omero/sysadmins/unix/install-web/walkthrough/omeroweb-install-centos7-ice3.6.html new file mode 100644 index 0000000000..88b3f94ed1 --- /dev/null +++ b/omero/sysadmins/unix/install-web/walkthrough/omeroweb-install-centos7-ice3.6.html @@ -0,0 +1,8 @@ + + + + + + \ No newline at end of file diff --git a/omero/sysadmins/unix/install-web/walkthrough/omeroweb-install-centos7-ice3.6.rst b/omero/sysadmins/unix/install-web/walkthrough/omeroweb-install-centos7-ice3.6.rst deleted file mode 100644 index 08b3e834a5..0000000000 --- a/omero/sysadmins/unix/install-web/walkthrough/omeroweb-install-centos7-ice3.6.rst +++ /dev/null @@ -1,410 +0,0 @@ -.. walkthroughs are generated using ansible, see -.. https://github.com/ome/omeroweb-install - -OMERO.web installation on CentOS 7 and IcePy 3.6 -================================================ - -Please first read :doc:`../../server-centos7-ice36`. - - -This is an example walkthrough for installing OMERO.web in a **virtual environment** using a dedicated system user. Installing OMERO.web in a virtual environment is the preferred way. For convenience in this walkthrough, we will use the **omero-web system user** and define the main OMERO.web configuration options as environment variables. Since 5.6, a new :envvar:`OMERODIR` variable is used, you should first unset :envvar:`OMERO_HOME` (if set) before beginning the installation process. By default, Python 3.6 is installed. - - -**The following steps are run as root.** - -If required, first create a local system user omero-web and create directory:: - - useradd -m omero-web - - mkdir -p /opt/omero/web/omero-web/etc/grid - chown -R omero-web /opt/omero/web/omero-web - - - -Installing prerequisites ------------------------- - -**The following steps are run as root.** - - -Install dependencies:: - - yum -y install epel-release - - yum -y install unzip - - yum -y install python3 - - yum -y install nginx - - -*Optional*: if you wish to use the Redis cache, install Redis:: - - yum -y install redis - - systemctl enable redis.service - - systemctl start redis.service - - -Creating a virtual environment ------------------------------- - -**The following steps are run as root.** - -Create the virtual environment. This is the recommended way to install OMERO.web:: - - python3 -mvenv /opt/omero/web/venv3 - - - - -Install ZeroC IcePy 3.6:: - - /opt/omero/web/venv3/bin/pip install https://github.com/ome/zeroc-ice-py-centos7/releases/download/0.2.1/zeroc_ice-3.6.5-cp36-cp36m-linux_x86_64.whl - - -Upgrade pip and install OMERO.web:: - - - /opt/omero/web/venv3/bin/pip install --upgrade pip - /opt/omero/web/venv3/bin/pip install omero-web - -Installing OMERO.web apps -------------------------- - - -A number of apps are available to add functionality to OMERO.web, such as `OMERO.figure `_ and `OMERO.iviewer `_. See the main website for a `list of released apps `_. These apps are optional and can be installed, as the **root user**, via :program:`pip` to your OMERO.web virtual environment and configured as the **omero-web system user**, at any time. - - - -Configuring OMERO.web ---------------------- - -**The following steps are run as the omero-web system user.** - -For convenience the main OMERO.web configuration options have been defined as environment variables. You can either use your own values, or alternatively use the following ones:: - - export WEBSESSION=True - export OMERODIR=/opt/omero/web/omero-web - - -Configure OMERO.web and create the NGINX OMERO configuration file to be included in a system-wide NGINX configuration by redirecting the output of the command ``omero web config nginx`` below into a file. If an attempt is made to access OMERO.web whilst it is not running, the generated NGINX configuration file will automatically display a maintenance page:: - - export PATH=/opt/omero/web/venv3/bin:$PATH - - - omero web config nginx --http "${WEBPORT}" --servername "${WEBSERVER_NAME}" > /opt/omero/web/omero-web/nginx.conf.tmp - -OMERO.web offers a number of configuration options. The configuration changes **will not be applied** until Gunicorn is restarted using ``omero web restart``. The Gunicorn workers are managed **separately** from other OMERO processes. You can check their status or stop them using ``omero web status`` or ``omero web stop``. - - - Session engine: - - - OMERO.web offers alternative session backends to automatically delete stale data using the cache session store backend, see :djangodoc:`Django cached session documentation ` for more details. - - - `Redis `_ requires `django-redis `_ in order to be used with OMERO.web. We assume that Redis has already been installed. To configure the cache, run:: - - omero config set omero.web.caches '{"default": {"BACKEND": "django_redis.cache. - RedisCache", "LOCATION": "redis://127.0.0.1:6379/0"}}' - - - After installing all the cache prerequisites set the following:: - - omero config set omero.web.session_engine django.contrib.sessions.backends.cache - - - - Use a prefix: - - By default OMERO.web expects to be run from the root URL of the webserver. - This can be changed by setting :property:`omero.web.prefix` and - :property:`omero.web.static_url`. For example, to make OMERO.web appear at - `http://example.org/omero/`:: - - omero config set omero.web.prefix '/omero' - omero config set omero.web.static_url '/omero/static/' - - and regenerate your webserver configuration. - - All configuration options can be found on various sections of - :ref:`web_index` developers documentation. For the full list, refer to - :ref:`web_configuration` properties. - - The most popular configuration options include: - - - Debug mode, see :property:`omero.web.debug`. - - - Customizing OMERO clients e.g. to add your own logo to the login page - (:property:`omero.web.login_logo`) or use an index page as an alternative - landing page for users (:property:`omero.web.index_template`). See - :doc:`/sysadmins/customization` for further information. - - - Enabling a public user see :doc:`/sysadmins/public`. - - -Configuring Gunicorn --------------------- - -**The following steps are run as the omero-web system user.** - -Additional settings can be configured by changing the properties below. Before changing the properties, run ``export PATH=/opt/omero/web/venv3/bin:$PATH``: - - - :property:`omero.web.wsgi_workers` to (2 x NUM_CORES) + 1 - - .. note:: - **Do not** scale the number of workers to the number of clients - you expect to have. OMERO.web should only need 4-12 worker - processes to handle many requests per second. - - - :property:`omero.web.wsgi_args` Additional arguments. For more details - check `Gunicorn Documentation `_. For example to enable **debugging**, run the following command:: - - omero config set omero.web.wsgi_args -- "--log-level=DEBUG --error-logfile=/opt/omero/web/omero-web/var/log/error.log" - - - -Setting up CORS ---------------- - - -**The following steps are run as root.** - -Cross Origin Resource Sharing allows web applications hosted at other origins to access resources from your OMERO.web installation. This can be achieved using the `django-cors-headers `_ app with additional configuration of OMERO.web. See the `django-cors-headers `_ page for more details on the settings. - Since OMERO.web 5.14.0, the package `django-cors-headers` is installed by default. - - - -**The following steps are run as the omero-web system user.** - -Configure CORS. An ``index`` is used to specify the ordering of middleware classes. It is important to add the ``CorsMiddleware`` as the first class and ``CorsPostCsrfMiddleware`` as the last. You can specify allowed origins in a whitelist, or allow all, for example:: - - omero config append omero.web.middleware '{"index": 0.5, "class": "corsheaders.middleware.CorsMiddleware"}' - omero config append omero.web.middleware '{"index": 10, "class": "corsheaders.middleware.CorsPostCsrfMiddleware"}' - omero config set omero.web.cors_origin_whitelist '["https://hostname.example.com"]' - # or to allow all - omero config set omero.web.cors_origin_allow_all True - -Configuring NGINX ------------------ - -**The following steps are run as root.** - -Copy the generated configuration file into the NGINX configuration directory, disable the default configuration and start NGINX:: - - sed -i.bak -re 's/( default_server.*)/; #\1/' /etc/nginx/nginx.conf - if [ -f /etc/nginx/conf.d/default.conf ]; then - mv /etc/nginx/conf.d/default.conf /etc/nginx/conf.d/default.disabled - fi - cp /opt/omero/web/omero-web/nginx.conf.tmp /etc/nginx/conf.d/omeroweb.conf - - systemctl enable nginx - - systemctl start nginx - - -For production servers you may need to add additional directives to the configuration file, for example to enable `HTTPS `_. As an alternative to manually modifying the generated file you can generate a minimal configuration and include this in your own manually created NGINX file, such as :file:`/etc/nginx/conf.d/omero-web.conf`: - - :: - - omero web config nginx-location > /opt/omero/web/omero-web/omero-web-location.include - - -This requires more initial work but in the future you can automatically regenerate your OMERO.web configuration and your additional configuration settings will still apply. - - .. note:: - If you need help configuring your firewall rules, see the - :doc:`/sysadmins/server-security` page. - - - -Running OMERO.web ------------------ - - -Since OMERO.web 5.16.0, the package `whitenoise` is installed by default. - - -*Optional*: Install `Django Redis `_:: - - /opt/omero/web/venv3/bin/pip install 'django-redis==5.0.0' - -**The following steps are run as the omero-web system user.** - -*Optional*: Configure the cache:: - - omero config set omero.web.caches '{"default": {"BACKEND": "django_redis.cache.RedisCache","LOCATION": "redis://127.0.0.1:6379/0"}}' - omero config set omero.web.session_engine 'django.contrib.sessions.backends.cache' - -Configure WhiteNoise and start OMERO.web manually to test the installation:: - - omero config append -- omero.web.middleware '{"index": 0, "class": "whitenoise.middleware.WhiteNoiseMiddleware"}' - - omero web start - - # Test installation e.g. curl -sL localhost:4080 - - omero web stop - -Automatically running OMERO.web -------------------------------- - - -**The following steps are run as root.** - -Should you wish to run OMERO.web automatically, a `systemd.service` file could be created. See below an example file `omero-web-systemd.service`:: - - [Unit] - Description=OMERO.web - # Not mandatory, NGINX may be running on a different server - Requires=nginx.service - After=network.service - - [Service] - User=omero-web - Type=forking - PIDFile=/opt/omero/web/omero-web/var/django.pid - Restart=no - RestartSec=10 - Environment="PATH=/opt/omero/web/venv3/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin" - Environment="OMERODIR=/opt/omero/web/omero-web" - ExecStart=/opt/omero/web/venv3/bin/omero web start - ExecStop=/opt/omero/web/venv3/bin/omero web stop - - [Install] - WantedBy=multi-user.target - -Copy the `systemd.service` file, then enable and start the service:: - - cp omero-web-systemd.service /etc/systemd/system/omero-web.service - - systemctl daemon-reload - - systemctl enable omero-web.service - - systemctl stop omero-web.service - - systemctl start omero-web.service - - - -Maintaining OMERO.web ---------------------- - -**The following steps are run as the omero-web system user.** - -You can manage the sessions using the following configuration options and commands: - - - Session cookies :property:`omero.web.session_expire_at_browser_close`: - - - A boolean that determines whether to expire the session when the user - closes their browser. - See :djangodoc:`Django Browser-length sessions vs. persistent - sessions documentation ` - for more details. The default value is ``True``:: - - omero config set omero.web.session_expire_at_browser_close "True" - - - The age of session cookies, in seconds. The default value is ``86400``:: - - omero config set omero.web.session_cookie_age 86400 - - - Clear session: - - Each session for a logged-in user in OMERO.web is kept in the session - store. Stale sessions can cause the store to grow with time. OMERO.web - uses by default the OS file system as the session store backend and - does not automatically purge stale sessions, see - :djangodoc:`Django file-based session documentation ` for more details. It is therefore the responsibility of the OMERO - administrator to purge the session cache using the provided management command:: - - omero web clearsessions - - It is recommended to call this command on a regular basis, for example - as a :download:`daily cron job <../../omero-web-cron>`, see - :djangodoc:`Django clearing the session store documentation ` for more information. - - - -Troubleshooting ---------------- - -**The following steps are run as the omero-web system user.** - -In order to identify why OMERO.web is not available run ``omero web status``. Then consult NGINX :file:`error.log` and :file:`/opt/omero/web/omero-web/var/log/OMEROweb.log`. - - -Configuring Gunicorn advanced options -------------------------------------- - -OMERO.web deployment can be configured with sync and async workers. **Sync workers** are faster and recommended for a data repository with :ref:`download_restrictions`. If you wish to offer users the ability to download data then you have to use **async workers**. OMERO.web is able to handle multiple clients on a single worker thread switching context as necessary while streaming binary data from OMERO.server. Depending on the traffic and scale of the repository you should configure connections and speed limits on your server to avoid blocking resources. We recommend you run benchmark and performance tests. It is also possible to apply :ref:`download_restrictions` and offer alternative access to binary data. - - .. note:: - Handling streaming request/responses requires proxy buffering - to be turned off. For more details refer to - `Gunicorn deployment `_ - and - `NGINX configuration `_. - - .. note:: - :property:`omero.web.application_server.max_requests` should be set to 0 - - - See - `Gunicorn design `_ for more details. - - - -Experimental: Sync workers -~~~~~~~~~~~~~~~~~~~~~~~~~~ - -**The following steps are run as root.** - -Install :pypi:`futures`:: - - /opt/omero/web/venv3/bin/pip install futures - -**The following steps are run as the omero-web system user.** - -To find out more about the number of worker threads for handling requests, see `Gunicorn threads `_. Additional settings can be configured by changing the following properties:: - - omero config set omero.web.wsgi_worker_class - omero config set omero.web.wsgi_threads $(2-4 x NUM_CORES) - - - -Experimental: Async workers -~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -**The following steps are run as root.** - -Install `Gevent >= 0.13 `_:: - - /opt/omero/web/venv3/bin/pip install 'gevent>=0.13' - - - -**The following steps are run as the omero-web system user.** - -To find out more about the maximum number of simultaneous clients, see `Gunicorn worker-connections `_. Additional settings can be configured by changing the following properties:: - - omero config set omero.web.wsgi_worker_class gevent - omero config set omero.web.wsgi_worker_connections 1000 - omero config set omero.web.application_server.max_requests 0 - - - -SELinux -------- - -**The following steps are run as root.** - - -If you are running a system with `SELinux enabled `_ and are unable to access OMERO.web you may need to adjust the security policy:: - - if [ $(getenforce) != Disabled ]; then - - yum -y install policycoreutils-python - setsebool -P httpd_read_user_content 1 - setsebool -P httpd_enable_homedirs 1 - semanage port -a -t http_port_t -p tcp 4080 - - fi - diff --git a/omero/sysadmins/unix/install-web/web-deployment.rst b/omero/sysadmins/unix/install-web/web-deployment.rst index 6c0deeab52..4cbe095940 100644 --- a/omero/sysadmins/unix/install-web/web-deployment.rst +++ b/omero/sysadmins/unix/install-web/web-deployment.rst @@ -51,9 +51,6 @@ Walkthroughs **Supported:** -:doc:`walkthrough/omeroweb-install-centos7-ice3.6` - Instructions for installing OMERO.web from scratch on CentOS 7 with Ice 3.6. - :doc:`walkthrough/omeroweb-install-ubuntu2004-ice3.6` Instructions for installing OMERO.web from scratch on Ubuntu 20.04 with Ice 3.6. @@ -62,7 +59,6 @@ Walkthroughs :titlesonly: :hidden: - walkthrough/omeroweb-install-centos7-ice3.6 walkthrough/omeroweb-install-rockylinux9-ice3.6 walkthrough/omeroweb-install-ubuntu2004-ice3.6 walkthrough/omeroweb-install-ubuntu2204-ice3.6 diff --git a/omero/sysadmins/unix/server-centos7-ice36.html b/omero/sysadmins/unix/server-centos7-ice36.html new file mode 100644 index 0000000000..8ea604184c --- /dev/null +++ b/omero/sysadmins/unix/server-centos7-ice36.html @@ -0,0 +1,8 @@ + + + + + + diff --git a/omero/sysadmins/unix/server-centos7-ice36.rst b/omero/sysadmins/unix/server-centos7-ice36.rst deleted file mode 100644 index 02289b9e33..0000000000 --- a/omero/sysadmins/unix/server-centos7-ice36.rst +++ /dev/null @@ -1,169 +0,0 @@ -.. walkthroughs are generated using a bash script, see -.. https://github.com/ome/omero-install - -OMERO.server installation on CentOS 7 -===================================== - -.. warning:: - CentOS 7 will reach End Of Life on June 30, 2024. We recommend to use - RHEL 9/Rocky 9 instead. Please read :doc:`server-rockylinux9-ice36`. - -This is an example walkthrough for installing OMERO on CentOS 7, using -a dedicated local system user. You can use this as a guide -for setting up your own test server. For production use you should also read -the pages listed under :ref:`index-optimizing-server`. -This guide will install Python 3.6. -Since 5.6, a new :envvar:`OMERODIR` variable is used, you should first unset :envvar:`OMERO_HOME` -(if set) before beginning the installation process. - -This guide describes how to install using the **recommended** versions for -Java, Ice, PostgreSQL. -This should be read in conjunction with :doc:`../version-requirements`. - -This guide **does not** describe how to install OMERO.web. -To deploy OMERO.web, please read -:doc:`install-web/walkthrough/omeroweb-install-centos7-ice3.6`. - -These instructions assume your Linux distribution is configured with a UTF-8 -locale (this is normally the default). - -For convenience in this walkthrough, we will use the **omero-server system user** and the main OMERO configuration options have -been defined as environment variables. When following this walkthrough you can -either use your own values, or alternatively create :file:`settings.env` for example under ``/tmp`` e.g. ``/tmp/settings.env`` containing the variables below and source it when required: - -.. literalinclude:: walkthrough/settings.env - :start-after: Substitute - -Installing prerequisites ------------------------- - -**The following steps are run as root.** - -Install Java |javaversion_recommended|, Ice |iceversion| and PostgreSQL |postgresversion|: - -To install Java |javaversion_recommended| and other dependencies: - -.. literalinclude:: walkthrough/walkthrough_centos7.sh - :start-after: #start-step01 - :end-before: #end-step01 - -To install Ice |iceversion|: - -.. literalinclude:: walkthrough/walkthrough_centos7.sh - :start-after: #start-recommended-ice - :end-before: #end-recommended-ice - -To install PostgreSQL |postgresversion|: - -.. literalinclude:: walkthrough/walkthrough_centos7.sh - :start-after: # install Postgres - :end-before: #end-step01 - -.. Note:: if you are installing PostgreSQL in a Docker container, some of the commands above will not work. For more details check `step01_centos7_pg_deps.sh - `_ - -Create a local omero-server system user, and a directory for the OMERO repository: - -.. literalinclude:: walkthrough/walkthrough_centos7.sh - :start-after: #start-step02 - :end-before: #end-step02 - -Make the :file:`settings.env` available to the omero-server system user by copying in to the user home directory. The file will need to be sourced each time you switch user. You could add ``. ~/settings.env`` to the omero-server system user ``bash`` profile. - -Create a database user and initialize a new database for OMERO: - -.. literalinclude:: walkthrough/walkthrough_centos7.sh - :start-after: #start-step03 - :end-before: #end-step03 - -Installing OMERO.server ------------------------ - -**The following step is run as root.** - -We recommend to create a virtual environment and install the Ice Python binding and the dependencies required by the server using ``pip``: - -.. literalinclude:: walkthrough/walkthrough_centos7.sh - :start-after: #start-step03bis - :end-before: #end-step03bis - -Download and unzip OMERO.server: - -.. literalinclude:: walkthrough/walkthrough_centos7.sh - :start-after: #start-release-ice36 - :end-before: #end-release-ice36 - -Change the ownership of the OMERO.server directory and create a symlink: - -.. literalinclude:: walkthrough/walkthrough_centos7.sh - :start-after: #end-release-ice36 - :end-before: #end-step04-pre - -Configuring OMERO.server ------------------------- - -**The following steps are run as the omero-server system user.** (``su - omero-server``) - -The variable ``OMERODIR`` set in :download:`settings.env ` above **must** point to the location where OMERO.server is installed. -e.g. ``OMERODIR=/path_to_omero_server/OMERO.server``. - -Note that this script requires the same environment variables that were set -earlier in `settings.env`, so you may need to copy and/or source this file as -the omero user. - -Configure the database and the location of the data directory: - -.. literalinclude:: walkthrough/walkthrough_centos7.sh - :start-after: #end-copy-omeroscript - :end-before: #end-step04 - -.. include:: ciphers - -.. literalinclude:: walkthrough/walkthrough_centos7.sh - :start-after: #start-seclevel - :end-before: #end-seclevel - -Additionally on CentOS7, it is necessary to prevent the OMERO.server from advertising Diffie-Hellmann key exchange to the clients. -While this key-exchange algorithm is disabled in the OMERO side, if it is advertised it can lead to client errors -(e.g. omero-py>=5.13.0), which will fail to connect to OMERO because of a dh-key error. To prevent this, it might be necessary to remove -Diffie-Hellmann key exchange from the IceSSL configuration. On CentOS7, this can be done by running the following code: - -.. literalinclude:: walkthrough/walkthrough_centos7.sh - :start-after: #start-diffie-hellman - :end-before: #end-diffie-hellman - -See also :doc:`../client-server-ssl`. - -Running OMERO.server --------------------- - -**The following steps are run as the omero-server system user.** (``su - omero-server``) - -OMERO should now be set up. To start the server run:: - - omero admin start - -Should you wish to start OMERO automatically, a `systemd service file` could be created. -An example :download:`omero-server-systemd.service ` -is available. - -Copy the ``systemd.service`` file and configure the service: - -.. literalinclude:: walkthrough/walkthrough_centos7.sh - :start-after: #start-step06 - :end-before: #end-step06 - -You can then start up the service. - -Securing OMERO --------------- - -**The following steps are run as root.** - -If multiple users have access to the machine running OMERO you should restrict -access to OMERO.server's configuration and runtime directories, and optionally -the OMERO data directory: - -.. literalinclude:: walkthrough/walkthrough_centos7.sh - :start-after: #start-step07 - :end-before: #end-step07 diff --git a/omero/sysadmins/unix/server-installation.rst b/omero/sysadmins/unix/server-installation.rst index 4ee5585d48..423bdc2020 100644 --- a/omero/sysadmins/unix/server-installation.rst +++ b/omero/sysadmins/unix/server-installation.rst @@ -26,10 +26,6 @@ Since 5.6, a new :envvar:`OMERODIR` variable is used, you should first unset :en **Supported:** -:doc:`server-centos7-ice36` - Instructions for installing OMERO.server from scratch on - CentOS 7 with Ice 3.6 and Python 3.6. - :doc:`server-ubuntu2004-ice36` Instructions for installing OMERO.server from scratch on Ubuntu 20.04 with Ice 3.6 and Python 3.8. @@ -46,7 +42,6 @@ Since 5.6, a new :envvar:`OMERODIR` variable is used, you should first unset :en :titlesonly: :hidden: - server-centos7-ice36 server-rockylinux9-ice36 server-ubuntu2004-ice36 server-ubuntu2204-ice36 diff --git a/omero/sysadmins/unix/walkthrough/walkthrough_centos7.sh b/omero/sysadmins/unix/walkthrough/walkthrough_centos7.sh deleted file mode 100644 index 8461d5efd3..0000000000 --- a/omero/sysadmins/unix/walkthrough/walkthrough_centos7.sh +++ /dev/null @@ -1,128 +0,0 @@ -#!/bin/bash -set -e -u -x - -#start-step01: As root, install dependencies -yum -y install epel-release - -yum -y install unzip wget bc - -# install Java -yum -y install java-11-openjdk - -# install dependencies - -yum -y install python3 -yum -y install openssl -#end-step01 -# install Ice -#start-recommended-ice -curl -sL https://zeroc.com/download/Ice/3.6/el7/zeroc-ice3.6.repo > \ -/etc/yum.repos.d/zeroc-ice3.6.repo - -yum -y install glacier2 \ -icebox \ -icegrid \ -icepatch2 \ -libfreeze3.6-c++ \ -libice3.6-c++ \ -libicestorm3.6 -#end-recommended-ice - - -# install Postgres -yum -y install https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm -yum -y install postgresql11-server postgresql11 - -PGSETUP_INITDB_OPTIONS=--encoding=UTF8 /usr/pgsql-11/bin/postgresql-11-setup initdb - -sed -i.bak -re 's/^(host.*)ident/\1md5/' /var/lib/pgsql/11/data/pg_hba.conf -systemctl start postgresql-11.service - -systemctl enable postgresql-11.service -#end-step01 - -#start-step02: As root, create a local omero-server system user and directory for the OMERO repository -useradd -mr omero-server -# Give a password to the omero user -# e.g. passwd omero-server -chmod a+X ~omero-server - -mkdir -p "$OMERO_DATA_DIR" -chown omero-server "$OMERO_DATA_DIR" -#end-step02 -#start-step03: As root, create a database user and a database -echo "CREATE USER $OMERO_DB_USER PASSWORD '$OMERO_DB_PASS'" | su - postgres -c psql -su - postgres -c "createdb -E UTF8 -O '$OMERO_DB_USER' '$OMERO_DB_NAME'" - -psql -P pager=off -h localhost -U "$OMERO_DB_USER" -l -#end-step03 - -#start-step03bis: As root, create a virtual env and install dependencies -# Create a virtual env -python3 -mvenv $VENV_SERVER - -# Upgrade pip -$VENV_SERVER/bin/pip install --upgrade pip - -# Install the Ice Python binding -$VENV_SERVER/bin/pip install https://github.com/ome/zeroc-ice-py-centos7/releases/download/0.2.1/zeroc_ice-3.6.5-cp36-cp36m-linux_x86_64.whl - -# Install server dependencies -$VENV_SERVER/bin/pip install omero-server -#end-step03bis - -#start-step04-pre: As root, download the OMERO.server -#start-release-ice36 -cd /opt/omero/server -SERVER=https://downloads.openmicroscopy.org/omero/5.6/server-ice36.zip -wget -q $SERVER -O OMERO.server-ice36.zip -unzip -q OMERO.server* -#end-release-ice36 -# change ownership of the folder -chown -R omero-server OMERO.server-* -ln -s OMERO.server-*/ OMERO.server -#end-step04-pre - -#start-step04: As the omero-server system user, configure it -#start-copy-omeroscript -cp settings.env step04_all_omero.sh setup_omero_db.sh ~omero -#end-copy-omeroscript -omero config set omero.data.dir "$OMERO_DATA_DIR" -omero config set omero.db.name "$OMERO_DB_NAME" -omero config set omero.db.user "$OMERO_DB_USER" -omero config set omero.db.pass "$OMERO_DB_PASS" -omero db script -f $OMERODIR/db.sql --password "$OMERO_ROOT_PASS" -psql -h localhost -U "$OMERO_DB_USER" "$OMERO_DB_NAME" < $OMERODIR/db.sql -#end-step04 -#start-seclevel -omero certificates -#end-seclevel - -#start-diffie-hellman -omero config set omero.glacier2.IceSSL.Ciphers=HIGH:!DH -#end-diffie-hellman - - -#start-step06: As root, run the scripts to start OMERO automatically -cp omero-server-systemd.service /etc/systemd/system/omero-server.service - -systemctl daemon-reload - -systemctl enable omero-server.service -#end-step06 - -#start-step07: As root, secure OMERO -chmod go-rwx $OMERODIR/etc $OMERODIR/var - -# Optionally restrict access to the OMERO data directory -# chmod go-rwx "$OMERO_DATA_DIR" -#end-step07 -#start-selinux - -if [ $(getenforce) != Disabled ]; then - yum -y install policycoreutils-python - setsebool -P httpd_read_user_content 1 - setsebool -P httpd_enable_homedirs 1 - semanage port -a -t http_port_t -p tcp 4080 -fi -#end-selinux diff --git a/omero/sysadmins/version-requirements.rst b/omero/sysadmins/version-requirements.rst index 48d3f353cd..9332e0f297 100644 --- a/omero/sysadmins/version-requirements.rst +++ b/omero/sysadmins/version-requirements.rst @@ -99,11 +99,11 @@ General overview for `RHEL * - `RHEL 7 `__ - June 2014 - June 2024 - - |Deprecated| + - |Dropped| * - `CentOS 7 `__ - June 2014 - June 2024 - - |Deprecated| + - |Dropped| * - `RHEL 8 `__ - May 2019 - Dec 2029 @@ -116,7 +116,7 @@ General overview for `RHEL - May 2022 - May 2032 - |Recommended| - * - `Rocky 9 `__ + * - `Rocky Linux 9 `__ - Jul 2022 - May 2032 - |Recommended| @@ -191,9 +191,7 @@ Package lists * - Operating system - Details - * - CentOS 7 / RHEL 7 - - `Reference `__ - * - Rocky 9 + * - Rocky Linux 9 - `Reference `__ * - Ubuntu - `Reference `__