Skip to content

Commit

Permalink
remove old extensions (if any)
Browse files Browse the repository at this point in the history
Will fix issue #30 : Old extension are never cleaned
  • Loading branch information
Christian Iuga committed Nov 13, 2023
1 parent 3630e1b commit 8a9ec68
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions tasks/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,21 @@
become: true
when: guacamole_openid_auth

- name: config | list previous extensions version
ansible.builtin.find:
paths: "/etc/guacamole/extensions/"
excludes: '*{{ guacamole_version }}*'
file_type: file
register: guacamole_previous_extensions

- name: config | Delete previous extensions version
ansible.builtin.file:
path: "{{ guacamole_extensions.path }}"
state: absent
loop: "{{ guacamole_previous_extensions.files }}"
loop_control:
loop_var: guacamole_extensions

- name: config | Creating Guacamole DB
community.mysql.mysql_db:
name: "{{ guacamole_mysql_db['name'] }}"
Expand Down

0 comments on commit 8a9ec68

Please sign in to comment.