From ebf413ff42be70740f468124ff40fefa677e90e4 Mon Sep 17 00:00:00 2001 From: Andrea Dell'Amico Date: Fri, 19 Jan 2018 16:14:10 +0100 Subject: [PATCH] accounting-service: cleanup the tasks. --- smartgears/accounting-service/defaults/main.yml | 1 - smartgears/accounting-service/tasks/main.yml | 7 ++----- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/smartgears/accounting-service/defaults/main.yml b/smartgears/accounting-service/defaults/main.yml index 671991d6..8136d11b 100644 --- a/smartgears/accounting-service/defaults/main.yml +++ b/smartgears/accounting-service/defaults/main.yml @@ -6,7 +6,6 @@ accounting_service_name: accounting-service accounting_service_extension: war accounting_service_file: '{{ accounting_service_name }}-{{ accounting_service_version }}.{{ accounting_service_extension }}' accounting_service_group_id: org.gcube.accounting -accounting_service_url: 'http://maven.research-infrastructures.eu/nexus/content/repositories/{{ gcube_repository }}' accounting_service_library_name: document-store-lib-accounting-service accounting_service_library_classifier: jar-with-dependencies diff --git a/smartgears/accounting-service/tasks/main.yml b/smartgears/accounting-service/tasks/main.yml index 31db42a7..059b539c 100644 --- a/smartgears/accounting-service/tasks/main.yml +++ b/smartgears/accounting-service/tasks/main.yml @@ -22,20 +22,17 @@ when: ( accounting_download | changed ) - name: Remove the accounting service library - shell: find {{ smartgears_instance_path }}/lib -name {{ accounting_service_library_name }}-\* -exec rm -fr {} \; - ignore_errors: yes + shell: rm -fr {{ smartgears_instance_path }}/lib/{{ accounting_service_library_name }}-* when: ( accounting_download | changed ) - name: Remove the accounting couchbase library if present - shell: find {{ smartgears_instance_path }}/lib -name {{ accounting_couchbase_library_name }}-\* -exec rm -fr {} \; - ignore_errors: yes + shell: rm -fr {{ smartgears_instance_path }}/lib/{{ accounting_couchbase_library_name }}-* when: ( accounting_download | changed ) - name: Get the couchbase library maven_artifact: artifact_id={{ accounting_couchbase_library_name }} version={{ accounting_couchbase_library_version | default('latest') }} group_id={{ accounting_couchbase_library_group_id }} extension={{ accounting_couchbase_library_extension | default('war') }} repository_url={{ smartgears_global_base_url }} classifier={{ accounting_service_library_classifier }} dest={{ smartgears_instance_path }}/lib when: ( accounting_download | changed ) - - name: Copy the accounting_service war file to the destination place copy: src={{ smartgears_downloads_dir }}/{{ accounting_service_file }} dest={{ smartgears_instance_path }}/webapps/{{ accounting_service_name }}.{{ accounting_service_extension }} remote_src=yes force=yes notify: Restart smartgears