forked from ISTI-ansible-roles/ansible-roles
library/roles: fixes to the fail2ban and iptables handlers. Remove some dependencies from the solr-tomcat-instance and tomcat-apache-requirements roles. They will need to be explicitly set.
This commit is contained in:
parent
b3a24547ce
commit
0df30e5cf7
|
@ -38,6 +38,18 @@
|
||||||
with_items: dnet_log_directories
|
with_items: dnet_log_directories
|
||||||
tags: [ 'tomcat', 'dnet', 'users' ]
|
tags: [ 'tomcat', 'dnet', 'users' ]
|
||||||
|
|
||||||
|
- name: Install additional packages, if needed
|
||||||
|
apt: pkg={{ item }} state=installed
|
||||||
|
with_items: dnet_additional_packages
|
||||||
|
when: dnet_additional_packages is defined
|
||||||
|
tags: ['dnet', 'pkgs']
|
||||||
|
|
||||||
|
- name: Install additional python modules, if needed
|
||||||
|
pip: name={{ item }} state=present
|
||||||
|
with_items: dnet_additional_python_modules
|
||||||
|
when: dnet_additional_python_modules is defined
|
||||||
|
tags: ['dnet', 'pkgs']
|
||||||
|
|
||||||
#
|
#
|
||||||
# Acls for the single tomcat instance
|
# Acls for the single tomcat instance
|
||||||
#
|
#
|
||||||
|
@ -79,16 +91,15 @@
|
||||||
acl: name={{ item.0.instance_path }}/{{ item.1 }} entity={{ dnet_group }} etype=group permissions=rwx state=present
|
acl: name={{ item.0.instance_path }}/{{ item.1 }} entity={{ dnet_group }} etype=group permissions=rwx state=present
|
||||||
when: tomcat_m_instances is defined
|
when: tomcat_m_instances is defined
|
||||||
with_nested:
|
with_nested:
|
||||||
- ' {{ tomcat_m_instances }}'
|
- '{{ tomcat_m_instances }}'
|
||||||
- [ 'webapps', 'common', 'common/classes' ]
|
- [ 'webapps', 'common', 'common/classes' ]
|
||||||
tags: [ 'tomcat', 'dnet', 'users' ]
|
tags: [ 'tomcat', 'dnet', 'users' ]
|
||||||
|
|
||||||
- name: Set the default read/write permissions on the tomcat webapps and common/classes directories. multiple tomcat instances
|
- name: Set the default read/write permissions on the tomcat webapps and common/classes directories. multiple tomcat instances
|
||||||
acl: name={{ item.0.instance_path }}/{{ item.1 }} entity={{ dnet_group }} etype=group permissions=rwx state=present default=yes
|
acl: name={{ item.0.instance_path }}/{{ item.1 }} entity={{ dnet_group }} etype=group permissions=rwx state=present default=yes
|
||||||
when: tomcat_m_instances is not defined
|
|
||||||
when: tomcat_m_instances is defined
|
when: tomcat_m_instances is defined
|
||||||
with_nested:
|
with_nested:
|
||||||
- ' {{ tomcat_m_instances }}'
|
- '{{ tomcat_m_instances }}'
|
||||||
- [ 'webapps', 'common', 'common/classes' ]
|
- [ 'webapps', 'common', 'common/classes' ]
|
||||||
tags: [ 'tomcat', 'dnet', 'users' ]
|
tags: [ 'tomcat', 'dnet', 'users' ]
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,6 @@
|
||||||
---
|
---
|
||||||
- name: Restart fail2ban
|
- name: Restart fail2ban
|
||||||
service: name=fail2ban state=restarted enabled=yes
|
service: name=fail2ban state=restarted enabled=yes
|
||||||
|
when: ( is_trusty ) or ( is_debian8 )
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -22,5 +22,5 @@
|
||||||
|
|
||||||
- name: Restart fail2ban
|
- name: Restart fail2ban
|
||||||
service: name=fail2ban state=restarted enabled=yes
|
service: name=fail2ban state=restarted enabled=yes
|
||||||
when: is_trusty
|
when: ( is_trusty ) or ( is_debian8 )
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
---
|
---
|
||||||
# solr
|
# solr
|
||||||
solr_http_port: 8983
|
solr_http_port: 8983
|
||||||
tomcat_http_port: '{{ solr_http_port }}'
|
|
||||||
tomcat_load_additional_default_conf: True
|
tomcat_load_additional_default_conf: True
|
||||||
tomcat_version: 7
|
tomcat_version: 7
|
||||||
# solr needs a lot of time to start if it needs to rebuild its indices
|
# solr needs a lot of time to start if it needs to rebuild its indices
|
||||||
|
@ -13,7 +12,7 @@ solr_config_name: hindex
|
||||||
solr_shards: 1
|
solr_shards: 1
|
||||||
solr_instance: '{{ solr_service }}'
|
solr_instance: '{{ solr_service }}'
|
||||||
solr_log_level: INFO
|
solr_log_level: INFO
|
||||||
solr_http_port_1: '{{ tomcat_http_port }}'
|
solr_http_port_1: '{{ solr_http_port }}'
|
||||||
solr_zoo_port: 9983
|
solr_zoo_port: 9983
|
||||||
solr_zoo_port_1: 9984
|
solr_zoo_port_1: 9984
|
||||||
solr_zoo_port_2: 9985
|
solr_zoo_port_2: 9985
|
||||||
|
|
|
@ -1,3 +0,0 @@
|
||||||
---
|
|
||||||
dependencies:
|
|
||||||
- role: '../../library/roles/tomcat-multiple-instances'
|
|
|
@ -1,8 +1,8 @@
|
||||||
---
|
---
|
||||||
dependencies:
|
#dependencies:
|
||||||
- role: '../../library/roles/oracle-jdk'
|
# - role: '../../library/roles/oracle-jdk'
|
||||||
- role: '../../library/roles/apache'
|
# - role: '../../library/roles/apache'
|
||||||
- role: '../../library/roles/tomcat'
|
# - role: '../../library/roles/tomcat'
|
||||||
when: tomcat_m_instances is not defined
|
# when: tomcat_m_instances is not defined
|
||||||
# - role: '../../library/roles/tomcat-multiple-instances'
|
# - role: '../../library/roles/tomcat-multiple-instances'
|
||||||
# when: tomcat_m_instances
|
# when: tomcat_m_instances
|
||||||
|
|
|
@ -1,23 +1,8 @@
|
||||||
---
|
---
|
||||||
- name: Install the apache proxy modules needed for tomcat
|
|
||||||
file: src=/etc/apache2/mods-available/{{ item }} dest=/etc/apache2/mods-enabled/{{ item }} state=link
|
|
||||||
with_items:
|
|
||||||
- proxy.load
|
|
||||||
- proxy_http.load
|
|
||||||
- proxy_ajp.load
|
|
||||||
notify: apache2 reload
|
|
||||||
tags:
|
|
||||||
- apache
|
|
||||||
- dnet
|
|
||||||
|
|
||||||
- name: Ensure that the jre/lib/endorsed exists
|
- name: Ensure that the jre/lib/endorsed exists
|
||||||
file: dest={{ jdk_java_home }}/jre/lib/endorsed state=directory owner=root group=root mode=0755
|
file: dest={{ jdk_java_home }}/jre/lib/endorsed state=directory owner=root group=root mode=0755
|
||||||
tags:
|
tags: apache
|
||||||
- apache
|
|
||||||
- dnet
|
|
||||||
|
|
||||||
- name: Install the xercesImpl.jar needed by the dnet applications
|
- name: Install the xercesImpl.jar needed by the dnet applications
|
||||||
copy: src=xercesImpl.jar dest={{ jdk_java_home }}/jre/lib/endorsed/xercesImpl.jar owner=root group=root mode=0644
|
copy: src=xercesImpl.jar dest={{ jdk_java_home }}/jre/lib/endorsed/xercesImpl.jar owner=root group=root mode=0644
|
||||||
tags:
|
tags: apache
|
||||||
- apache
|
|
||||||
- dnet
|
|
||||||
|
|
|
@ -16,7 +16,11 @@
|
||||||
limitations under the License.
|
limitations under the License.
|
||||||
-->
|
-->
|
||||||
|
|
||||||
|
{% if item.shutdown_port == '-1' %}
|
||||||
|
<Server port="{{ item.shutdown_port }}" shutdown="SHUTDOWN_PORT_DISABLED">
|
||||||
|
{% else %}
|
||||||
<Server port="{{ item.shutdown_port }}" shutdown="{{ tomcat_m_shutdown_pwd }}">
|
<Server port="{{ item.shutdown_port }}" shutdown="{{ tomcat_m_shutdown_pwd }}">
|
||||||
|
{% endif %}
|
||||||
<Listener className="org.apache.catalina.core.JasperListener" />
|
<Listener className="org.apache.catalina.core.JasperListener" />
|
||||||
<!-- Prevent memory leaks due to use of particular java/javax APIs-->
|
<!-- Prevent memory leaks due to use of particular java/javax APIs-->
|
||||||
<Listener className="org.apache.catalina.core.JreMemoryLeakPreventionListener" />
|
<Listener className="org.apache.catalina.core.JreMemoryLeakPreventionListener" />
|
||||||
|
|
Loading…
Reference in New Issue