ckan-connector, r-connector, resource-registry: Remove the war file from tomcat/webapps when upgrading.
This commit is contained in:
parent
045ebf9416
commit
478ad025f2
|
@ -5,7 +5,7 @@
|
|||
with_items:
|
||||
- '{{ smartgears_instance_path }}/webapps/{{ ckan_connector_name }}'
|
||||
- '{{ smartgears_instance_path }}/webapps/{{ ckan_connector_name }}.{{ ckan_connector_extension }}'
|
||||
when: smartgears_upgrade
|
||||
notify: Restart smartgears
|
||||
|
||||
- name: Remove the CKAN connector fixer script
|
||||
become_user: root
|
||||
|
@ -22,8 +22,12 @@
|
|||
register: ckan_connector_download
|
||||
|
||||
- name: Remove the installed CKAN connector before upgrading
|
||||
file: dest={{ smartgears_instance_path }}/webapps/{{ ckan_connector_name }} state=absent
|
||||
file: dest={{ item }} state=absent
|
||||
with_items:
|
||||
- '{{ smartgears_instance_path }}/webapps/{{ ckan_connector_name }}'
|
||||
- '{{ smartgears_instance_path }}/webapps/{{ ckan_connector_name }}.{{ ckan_connector_extension }}'
|
||||
when: ( ckan_connector_download | changed )
|
||||
notify: Restart smartgears
|
||||
|
||||
- name: Create the CKAN connector webapp directory
|
||||
file: dest={{ smartgears_instance_path }}/webapps/{{ ckan_connector_name }} state=directory
|
||||
|
@ -33,6 +37,7 @@
|
|||
unarchive: copy=no src={{ smartgears_downloads_dir }}/{{ ckan_connector_filename }} dest={{ smartgears_instance_path }}/webapps/{{ ckan_connector_name }}
|
||||
args:
|
||||
creates: '{{ smartgears_instance_path }}/webapps/{{ ckan_connector_name }}/WEB-INF/web.xml'
|
||||
notify: Restart smartgears
|
||||
|
||||
- name: Install the CKAN connector web.xml template
|
||||
template: src=ckan-web.xml.j2 dest={{ smartgears_instance_path }}/webapps/ckan-connector/WEB-INF/.web.xml.tpl mode=0440
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
become: True
|
||||
become_user: '{{ smartgears_user }}'
|
||||
when: not r_connector_install
|
||||
notify: Restart smartgears
|
||||
tags: [ 'smartgears', 'r_connector', 'tomcat' ]
|
||||
|
||||
- block:
|
||||
|
@ -32,7 +33,11 @@
|
|||
register: r_connector_download
|
||||
|
||||
- name: Remove the installed R connector before upgrading
|
||||
file: dest={{ smartgears_instance_path }}/webapps/{{ r_connector_name }} state=absent
|
||||
file: dest={{ item }} state=absent
|
||||
with_items:
|
||||
- '{{ smartgears_instance_path }}/webapps/{{ r_connector_name }}'
|
||||
- '{{ smartgears_instance_path }}/webapps/{{ r_connector_name }}.{{ r_connector_extension }}'
|
||||
notify: Restart smartgears
|
||||
when: ( r_connector_download | changed )
|
||||
|
||||
- name: Create the R connector webapp directory
|
||||
|
@ -43,6 +48,7 @@
|
|||
unarchive: copy=no src={{ smartgears_downloads_dir }}/{{ r_connector_filename }} dest={{ smartgears_instance_path }}/webapps/{{ r_connector_name }}
|
||||
args:
|
||||
creates: '{{ smartgears_instance_path }}/webapps/{{ r_connector_name }}/WEB-INF/web.xml'
|
||||
notify: Restart smartgears
|
||||
|
||||
- name: Obtain the permission to read the Rstudio secure cookie key
|
||||
become_user: root
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
with_items:
|
||||
- '{{ smartgears_instance_path }}/webapps/{{ resource_registry_name }}'
|
||||
- '{{ smartgears_instance_path }}/webapps/{{ resource_registry_name }}.{{ resource_registry_extension }}'
|
||||
notify: Restart smartgears
|
||||
|
||||
become: True
|
||||
become_user: '{{ d4science_user }}'
|
||||
|
@ -17,17 +18,16 @@
|
|||
register: resource_registry_download
|
||||
|
||||
- name: Remove the old resource-registry files
|
||||
file: path={{ smartgears_instance_path }}/webapps/{{ resource_registry_name }} state=absent
|
||||
file: path={{ item }} state=absent
|
||||
with_items:
|
||||
- '{{ smartgears_instance_path }}/webapps/{{ resource_registry_name }}'
|
||||
- '{{ smartgears_instance_path }}/webapps/{{ resource_registry_name }}.{{ resource_registry_extension }}'
|
||||
when: ( resource_registry_download | changed )
|
||||
|
||||
- name: Create the resource-registry working directory
|
||||
file: path={{ smartgears_instance_path }}/webapps/{{ resource_registry_name }} state=directory owner={{ smartgears_user }} group={{ smartgears_user }}
|
||||
when: ( resource_registry_download | changed )
|
||||
|
||||
- name: Copy the resource registry war file into the webapps directory
|
||||
copy: src={{ smartgears_downloads_dir }}/{{ resource_registry_file }} dest={{ smartgears_instance_path }}/webapps/{{ resource_registry_name }}.{{ resource_registry_extension }} remote_src=yes force=yes
|
||||
notify: Restart smartgears
|
||||
|
||||
- name: Unarchive the resource registry war
|
||||
unarchive: copy=no src={{ smartgears_downloads_dir }}/{{ resource_registry_file }} dest={{ smartgears_instance_path }}/webapps/{{ resource_registry_name }} creates={{ smartgears_instance_path }}/webapps/{{ resource_registry_name }}/WEB-INF/lib
|
||||
notify: Restart smartgears
|
||||
|
|
Loading…
Reference in New Issue