mirror of
https://github.com/iiab/iiab.git
synced 2025-03-09 15:40:17 +00:00
Modernize matomo/tasks/main.yml for skip_role_on_error #3255
This commit is contained in:
parent
c6ee32d0c0
commit
cd6358514d
1 changed files with 29 additions and 23 deletions
|
@ -19,31 +19,37 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
- name: Enable/Disable/Reload NGINX for OSM, if nginx_enabled
|
- block:
|
||||||
include_tasks: nginx.yml
|
|
||||||
|
|
||||||
|
- name: Enable/Disable/Reload NGINX for OSM, if nginx_enabled
|
||||||
|
include_tasks: nginx.yml
|
||||||
|
|
||||||
- name: Install Matomo if 'matomo_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Matomo if 'matomo_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: matomo_installed is undefined
|
when: matomo_installed is undefined
|
||||||
|
|
||||||
|
# LET'S ADD THIS "ON/OFF SWITCH" IF POSS!
|
||||||
|
# - include_tasks: enable-or-disable.yml
|
||||||
|
|
||||||
# LET'S ADD THIS "ON/OFF SWITCH" IF POSS!
|
- name: Add 'matomo' variable values to {{ iiab_ini_file }}
|
||||||
# - include_tasks: enable-or-disable.yml
|
ini_file:
|
||||||
|
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
||||||
|
section: matomo
|
||||||
|
option: "{{ item.option }}"
|
||||||
|
value: "{{ item.value | string }}"
|
||||||
|
with_items:
|
||||||
|
- option: name
|
||||||
|
value: Matomo
|
||||||
|
- option: description
|
||||||
|
value: '"Matomo is a web analytics alternative to Google Analytics, emphasizing privacy and data ownership."'
|
||||||
|
- option: matomo_install
|
||||||
|
value: "{{ matomo_install }}"
|
||||||
|
- option: matomo_enabled
|
||||||
|
value: "{{ matomo_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
- name: Add 'matomo' variable values to {{ iiab_ini_file }}
|
fail:
|
||||||
ini_file:
|
msg: ""
|
||||||
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
when: not skip_role_on_error
|
||||||
section: matomo
|
|
||||||
option: "{{ item.option }}"
|
|
||||||
value: "{{ item.value | string }}"
|
|
||||||
with_items:
|
|
||||||
- option: name
|
|
||||||
value: Matomo
|
|
||||||
- option: description
|
|
||||||
value: '"Matomo is a web analytics alternative to Google Analytics, emphasizing privacy and data ownership."'
|
|
||||||
- option: matomo_install
|
|
||||||
value: "{{ matomo_install }}"
|
|
||||||
- option: matomo_enabled
|
|
||||||
value: "{{ matomo_enabled }}"
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue