forked from ISTI-ansible-roles/ansible-roles
library/roles/smartgears/gcubeapp-setup: Fix the case where multiple apps are involved.
This commit is contained in:
parent
baf4e046ce
commit
bf9eaa3309
|
@ -2,6 +2,6 @@
|
|||
gcubeapp_setup: False
|
||||
|
||||
#gcubeapp_webapps:
|
||||
# - { webapp_name: '', version: '', webapp_group: '', description: '', exclude_handlers: [ '' ] }
|
||||
# - { webapp_path: '', webapp_name: '', version: '', webapp_group: '', description: '', exclude_handlers: [ '' ] }
|
||||
|
||||
|
||||
|
|
|
@ -1,10 +1,8 @@
|
|||
---
|
||||
- name: Install the gcube-app file to make the webapp smartgears compatible
|
||||
template: src=gcube-app.xml.j2 dest={{ item.0.instance_path }}/webapps/{{ item.1.webapp_name }}/WEB-INF/gcube-app.xml owner={{ item.0.user }} group={{ item.0.user }}
|
||||
with_together:
|
||||
- '{{ tomcat_m_instances }}'
|
||||
- '{{ gcubeapp_webapps | default (omit) }}'
|
||||
notify: tomcat instances restart
|
||||
template: src=gcube-app.xml.j2 dest={{ item.webapp_path | default('/home/gcube/tomcat') }}/webapps/{{ item.webapp_name }}/WEB-INF/gcube-app.xml owner={{ smartgears_user }} group={{ smartgears_user }}
|
||||
with_items: '{{ gcubeapp_webapps | default (omit) }}'
|
||||
notify: Restart smartgears
|
||||
when: gcubeapp_setup
|
||||
tags: [ 'smartgears', 'gcubeapp' ]
|
||||
|
||||
|
|
|
@ -1,16 +1,16 @@
|
|||
<application mode="online">
|
||||
|
||||
<name>{{ item.1.webapp_name }}</name>
|
||||
<group>{{ item.1.webapp_group }}</group>
|
||||
<version>{{ item.1.version }}</version>
|
||||
{% if item.1.description is defined %}
|
||||
<description> "{{ item.1.description }}" </description>
|
||||
<name>{{ item.webapp_name }}</name>
|
||||
<group>{{ item.webapp_group }}</group>
|
||||
<version>{{ item.version }}</version>
|
||||
{% if item.description is defined %}
|
||||
<description> "{{ item.description }}" </description>
|
||||
{% endif %}
|
||||
{% if item.1.persistence_location is defined %}
|
||||
<persistence location="{{ item.1.persistence_location }}"/>
|
||||
{% if item.persistence_location is defined %}
|
||||
<persistence location="{{ item.persistence_location }}"/>
|
||||
{% endif %}
|
||||
{% if item.1.exclude_handlers is defined %}
|
||||
{% for eh in item.1.exclude_handlers %}
|
||||
{% if item.exclude_handlers is defined %}
|
||||
{% for eh in item.exclude_handlers %}
|
||||
<exclude {{ eh }}</exclude>
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
|
Loading…
Reference in New Issue