<commit_before># ansible-tomcat

Install Tomcat with configurable Catalina instances.

## Compatibility

### 0.8.0

Starting with this role version managing instances has been changed
significantly, mostly to better support capabilities from Systemd
(e.g. templated services).
Updating the role requires to reconfigure inventory. So please be
aware of ``tomcat_instances`` documentation below.


## Requirements

This role requires local facts in */etc/ansible/facts.d/java.fact*
to be available. The following variable must be available for the
default service templates to work:

* ``java_home``

Facts are used as

* ``ansible_local.java.general.java_home``

[groover.java](https://github.com/silpion/ansible-java) role may get
used to automatically fulfill the requirements.


## Dependencies

This role depends on [groover.util](https://github.com/silpion/ansible-util)
role. This is configured for ``ansible-galaxy install`` in **requirements.yml**.

**NOTE**: Requirements are installed as virtual user ``silpion``
(``silpion.util``).

Be sure to install required roles with

    ansible-galaxy install --role-file requirements.yml

## Role variables

* ``tomcat_version``: Configure Tomcat version (string, default: ``7.0.62``)
* ``tomcat_mirror``: Configure Tomcat mirror site (string, default: ``http://archive.apache.org/dist/tomcat``)
* ``tomcat_download_url``: Configure complete URL to download Tomcat from (string, default: ``{{ tomcat_mirror }}/tomcat-{{ tomcat_version_major }}/v{{ tomcat_version }}/bin/{{ tomcat_redis_filename }}``)
* ``tomcat_install_base``: Configure base/installation directory for Tomcat (string, default: ``/opt/tomcat``)
* ``tomcat_default_user_group``: Default group for the user account to run Tomcat as when not configured per instance (string, default: ``tomcat``)
* ``tomcat_default_user_name``: Default user account to run Tomcat as when not configured per instance (string, default: ``tomcat``)
* ``tomcat_default_user_home``: Default home directory for the user account to run Tomcat as when not configured per instance (string, default: ``/srv/{{ tomcat_default_user_name }}``)
* ``tomcat_instances``: Configure Catalina instances (list, default: ``{ - name: tomcat }``)
* ``tomcat_default_server_xml_template``: Default server.xml template to use for configuring Tomcat instances (string, default: ``server.xml.j2``)
* ``tomcat_default_web_xml_template``: Default web.xml template to use for configuring Tomcat instances (string, default: ``web.xml.j2``)
* ``tomcat_default_port_ajp``: Default AJP port when not configured per instance (int, default: ``8009``)
* ``tomcat_default_port_connector``: Default connector port when not configured per instance (int, default: ``8080``)
* ``tomcat_default_port_redirect``: Default redirect port when not configured per instance (int, default: ``8443``)
* ``tomcat_default_port_shutdown``: Default shutdown port when not configured per instance (int, default: ``8005``)
* ``tomcat_default_catalina_opts``: Default configuration for environment variable "CATALINA\_OPTS" when not configured per instance (string, default: ``''``)
* ``tomcat_default_instance_path``: Default configuration for base path per instance (string, default: ``/srv/{{ tomcat_default_user_name }}``)
* ``tomcat_server_systemd_template``: Default template to use when configuring Tomcat for Systemd (string, default: ``service_systemd.j2`` (see ``vars/service/systemd.yml``))
* ``tomcat_server_sysvinit_template``: Default template to use when configuring Tomcat for SysV (string, default: ``service_sysvinit.j2`` (see ``vars/service/sysvinit.yml``))
* ``tomcat_server_upstart_template``: Default template to use when configuring Tomcat for upstart (string, default: ``service_upstart.j2`` (see ``vars/service/upstart.yml``))
* ``tomcat_service_allow_restart``: Whether to allow or deny restarting Tomcat instances automatically (boolean, default: ``true``)
* ``tomcat_facts_template``: Default template to use when configuring Tomcat facts.d (string, default: ``facts.j2``)
* ``tomcat_default_override_uri_encoding``: Default URI encoding for Tomcat (string, default: ``""``)

### tomcat_instances

Instance configuration default variables may get configured per<commit_msg>Update documentation to reflect tomcat_version update to 7.0.65<commit_after># ansible-tomcat

Install Tomcat with configurable Catalina instances.

## Compatibility

### 0.8.0

Starting with this role version managing instances has been changed
significantly, mostly to better support capabilities from Systemd
(e.g. templated services).
Updating the role requires to reconfigure inventory. So please be
aware of ``tomcat_instances`` documentation below.


## Requirements

This role requires local facts in */etc/ansible/facts.d/java.fact*
to be available. The following variable must be available for the
default service templates to work:

* ``java_home``

Facts are used as

* ``ansible_local.java.general.java_home``

[groover.java](https://github.com/silpion/ansible-java) role may get
used to automatically fulfill the requirements.


## Dependencies

This role depends on [groover.util](https://github.com/silpion/ansible-util)
role. This is configured for ``ansible-galaxy install`` in **requirements.yml**.

**NOTE**: Requirements are installed as virtual user ``silpion``
(``silpion.util``).

Be sure to install required roles with

    ansible-galaxy install --role-file requirements.yml

## Role variables

* ``tomcat_version``: Configure Tomcat version (string, default: ``7.0.65``)
* ``tomcat_mirror``: Configure Tomcat mirror site (string, default: ``http://archive.apache.org/dist/tomcat``)
* ``tomcat_download_url``: Configure complete URL to download Tomcat from (string, default: ``{{ tomcat_mirror }}/tomcat-{{ tomcat_version_major }}/v{{ tomcat_version }}/bin/{{ tomcat_redis_filename }}``)
* ``tomcat_install_base``: Configure base/installation directory for Tomcat (string, default: ``/opt/tomcat``)
* ``tomcat_default_user_group``: Default group for the user account to run Tomcat as when not configured per instance (string, default: ``tomcat``)
* ``tomcat_default_user_name``: Default user account to run Tomcat as when not configured per instance (string, default: ``tomcat``)
* ``tomcat_default_user_home``: Default home directory for the user account to run Tomcat as when not configured per instance (string, default: ``/srv/{{ tomcat_default_user_name }}``)
* ``tomcat_instances``: Configure Catalina instances (list, default: ``{ - name: tomcat }``)
* ``tomcat_default_server_xml_template``: Default server.xml template to use for configuring Tomcat instances (string, default: ``server.xml.j2``)
* ``tomcat_default_web_xml_template``: Default web.xml template to use for configuring Tomcat instances (string, default: ``web.xml.j2``)
* ``tomcat_default_port_ajp``: Default AJP port when not configured per instance (int, default: ``8009``)
* ``tomcat_default_port_connector``: Default connector port when not configured per instance (int, default: ``8080``)
* ``tomcat_default_port_redirect``: Default redirect port when not configured per instance (int, default: ``8443``)
* ``tomcat_default_port_shutdown``: Default shutdown port when not configured per instance (int, default: ``8005``)
* ``tomcat_default_catalina_opts``: Default configuration for environment variable "CATALINA\_OPTS" when not configured per instance (string, default: ``''``)
* ``tomcat_default_instance_path``: Default configuration for base path per instance (string, default: ``/srv/{{ tomcat_default_user_name }}``)
* ``tomcat_server_systemd_template``: Default template to use when configuring Tomcat for Systemd (string, default: ``service_systemd.j2`` (see ``vars/service/systemd.yml``))
* ``tomcat_server_sysvinit_template``: Default template to use when configuring Tomcat for SysV (string, default: ``service_sysvinit.j2`` (see ``vars/service/sysvinit.yml``))
* ``tomcat_server_upstart_template``: Default template to use when configuring Tomcat for upstart (string, default: ``service_upstart.j2`` (see ``vars/service/upstart.yml``))
* ``tomcat_service_allow_restart``: Whether to allow or deny restarting Tomcat instances automatically (boolean, default: ``true``)
* ``tomcat_facts_template``: Default template to use when configuring Tomcat facts.d (string, default: ``facts.j2``)
* ``tomcat_default_override_uri_encoding``: Default URI encoding for Tomcat (string, default: ``""``)

### tomcat_instances

Instance configuration default variables may get configured per
{'fraction_non_alphanumeric': 0.12168815943728019, 'fraction_numerical': 0.007268464243845252, 'mean_word_length': 6.483333333333333, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 12}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6969648', 'n_tokens_mistral': 2523, 'n_tokens_neox': 2450, 'n_words': 836}