diff --git a/ansible/roles/cleaner/scenarios/delfin.yml b/ansible/roles/cleaner/scenarios/delfin.yml index 0487a2bf8..479bd6647 100644 --- a/ansible/roles/cleaner/scenarios/delfin.yml +++ b/ansible/roles/cleaner/scenarios/delfin.yml @@ -20,6 +20,7 @@ - name: Kill running delfin processes shell: "kill {{ item }}" with_items: "{{ running_processes.stdout_lines }}" + ignore_errors: yes - wait_for: path: "/proc/{{ item }}/status" @@ -40,6 +41,7 @@ - rabbitmq-server - redis-server become: yes + ignore_errors: yes - name: clean up all delfin directories file: diff --git a/ansible/roles/delfin-installer/scenarios/redis.yml b/ansible/roles/delfin-installer/scenarios/redis.yml index f324c5240..d0855dbd4 100644 --- a/ansible/roles/delfin-installer/scenarios/redis.yml +++ b/ansible/roles/delfin-installer/scenarios/redis.yml @@ -19,10 +19,10 @@ register: redisservice - name: Ensure Redis is present - apt: - name: redis-server - state: latest - become: yes + shell: "{{ item }}" + with_items: + - ulimit -n 65536 + - apt-get install -y redis-server when: - redisservice.stat.exists is undefined or redisservice.stat.exists == false @@ -33,9 +33,8 @@ replace: "port {{ delfin_redis_port }}" become: yes -- name: Ensure Redis is started +- name: Ensure Redis is restarted service: - name: redis-server - state: started - enabled: yes + name: redis-server + state: restarted become: yes diff --git a/ansible/site.yml b/ansible/site.yml index 95555b443..62759f8c8 100644 --- a/ansible/site.yml +++ b/ansible/site.yml @@ -83,6 +83,21 @@ - deploy_project != "gelato" tags: dock +- name: Install delfin + hosts: controllers + remote_user: root + vars_files: + - group_vars/common.yml + - group_vars/delfin.yml + gather_facts: false + become: True + tasks: + - import_role: + name: delfin-installer + when: + - enable_delfin == true + tags: delfin + - name: Install Gelato hosts: controllers remote_user: root @@ -167,17 +182,3 @@ - enable_orchestration == true tags: orchestration -- name: Install delfin - hosts: controllers - remote_user: root - vars_files: - - group_vars/common.yml - - group_vars/delfin.yml - gather_facts: false - become: True - tasks: - - import_role: - name: delfin-installer - when: - - enable_delfin == true - tags: delfin