mirror of
https://github.com/iiab/iiab.git
synced 2025-03-09 15:40:17 +00:00
Support skip_role_on_error in 23+2 more roles (Stages 6-9)
This commit is contained in:
parent
83ea6ce852
commit
8749e66a0b
33 changed files with 914 additions and 743 deletions
|
@ -19,15 +19,15 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install AWStats if 'awstats_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install AWStats if 'awstats_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: awstats_installed is undefined
|
when: awstats_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- name: Enable/Disable/Restart NGINX
|
- name: Enable/Disable/Restart NGINX
|
||||||
include_tasks: nginx.yml
|
include_tasks: nginx.yml
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'awstats' variable values to {{ iiab_ini_file }}
|
- name: Add 'awstats' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
||||||
|
@ -43,3 +43,10 @@
|
||||||
value: "{{ awstats_install }}"
|
value: "{{ awstats_install }}"
|
||||||
- option: awstats_enabled
|
- option: awstats_enabled
|
||||||
value: "{{ awstats_enabled }}"
|
value: "{{ awstats_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,14 +19,14 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install Calibre-Web if 'calibreweb_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Calibre-Web if 'calibreweb_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: calibreweb_installed is undefined
|
when: calibreweb_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- include_tasks: enable-or-disable.yml
|
- include_tasks: enable-or-disable.yml
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'calibre-web' variable values to {{ iiab_ini_file }}
|
- name: Add 'calibre-web' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
||||||
|
@ -56,3 +56,10 @@
|
||||||
value: "{{ calibreweb_port }}"
|
value: "{{ calibreweb_port }}"
|
||||||
- option: calibreweb_settings_database
|
- option: calibreweb_settings_database
|
||||||
value: "{{ calibreweb_settings_database }}"
|
value: "{{ calibreweb_settings_database }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
29
roles/calibre/tasks/enable-or-disable.yml
Normal file
29
roles/calibre/tasks/enable-or-disable.yml
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
# http://box:8080 & http://box:8080/mobile WORK BUT OTHER URL'S LIKE http://box/calibre ARE A MESS (BOOKS RARELY DISPLAY)
|
||||||
|
#
|
||||||
|
# 2018-08-27 POSSIBLE FIX...CONSIDER THIS ProxyPass / ProxyPassReverse TECHNIQUE:
|
||||||
|
# https://github.com/iiab/iiab/tree/master/roles/calibre-web/templates/calibre-web.conf.j2
|
||||||
|
# (anyway this works great for calibre-web, allowing http://box/books
|
||||||
|
# to work even better than http://box:8083 when box == 192.168.0.x !)
|
||||||
|
#
|
||||||
|
#- name: Attempt to enable http://box/calibre via Apache (UNTESTED)
|
||||||
|
# command: a2ensite calibre.conf
|
||||||
|
# when: apache_installed and calibre_enabled
|
||||||
|
#
|
||||||
|
#- name: Attempt to disable http://box/calibre via Apache (UNTESTED)
|
||||||
|
# command: a2dissite calibre.conf
|
||||||
|
# when: apache_installed and not calibre_enabled
|
||||||
|
|
||||||
|
- name: Enable & (Re)Start 'calibre-serve' service, if calibre_enabled
|
||||||
|
systemd:
|
||||||
|
daemon_reload: yes
|
||||||
|
name: calibre-serve
|
||||||
|
enabled: yes
|
||||||
|
state: restarted
|
||||||
|
when: calibre_enabled
|
||||||
|
|
||||||
|
- name: Disable & Stop 'calibre-serve' service, if not calibre_enabled
|
||||||
|
systemd:
|
||||||
|
name: calibre-serve
|
||||||
|
enabled: no
|
||||||
|
state: stopped
|
||||||
|
when: not calibre_enabled
|
|
@ -19,48 +19,13 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install Calibre if 'calibre_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Calibre if 'calibre_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: calibre_installed is undefined
|
when: calibre_installed is undefined
|
||||||
|
|
||||||
# http://box:8080 & http://box:8080/mobile WORK BUT OTHER URL'S LIKE http://box/calibre ARE A MESS (BOOKS RARELY DISPLAY)
|
- include_tasks: enable-or-disable.yml
|
||||||
#
|
|
||||||
# 2018-08-27 POSSIBLE FIX...CONSIDER THIS ProxyPass / ProxyPassReverse TECHNIQUE:
|
|
||||||
# https://github.com/iiab/iiab/tree/master/roles/calibre-web/templates/calibre-web.conf.j2
|
|
||||||
# (anyway this works great for calibre-web, allowing http://box/books
|
|
||||||
# to work even better than http://box:8083 when box == 192.168.0.x !)
|
|
||||||
#
|
|
||||||
#- name: Attempt to enable http://box/calibre via Apache (UNTESTED)
|
|
||||||
# command: a2ensite calibre.conf
|
|
||||||
# when: apache_installed and calibre_enabled
|
|
||||||
#
|
|
||||||
#- name: Attempt to disable http://box/calibre via Apache (UNTESTED)
|
|
||||||
# command: a2dissite calibre.conf
|
|
||||||
# when: apache_installed and not calibre_enabled
|
|
||||||
|
|
||||||
- name: Enable & (Re)Start 'calibre-serve' service, if calibre_enabled
|
|
||||||
systemd:
|
|
||||||
daemon_reload: yes
|
|
||||||
name: calibre-serve
|
|
||||||
enabled: yes
|
|
||||||
state: restarted
|
|
||||||
when: calibre_enabled
|
|
||||||
|
|
||||||
- name: Disable & Stop 'calibre-serve' service, if not calibre_enabled
|
|
||||||
systemd:
|
|
||||||
name: calibre-serve
|
|
||||||
enabled: no
|
|
||||||
state: stopped
|
|
||||||
when: not calibre_enabled
|
|
||||||
|
|
||||||
#- name: Enable/Disable/Restart Apache if primary
|
|
||||||
# include_tasks: apache.yml
|
|
||||||
# when: not nginx_enabled
|
|
||||||
#
|
|
||||||
#- name: Enable/Disable/Restart NGINX if primary
|
|
||||||
# include_tasks: nginx.yml
|
|
||||||
# when: nginx_enabled
|
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'calibre' variable values to {{ iiab_ini_file }}
|
- name: Add 'calibre' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
|
@ -81,3 +46,10 @@
|
||||||
value: "{{ calibre_port }}"
|
value: "{{ calibre_port }}"
|
||||||
- option: calibre_enabled
|
- option: calibre_enabled
|
||||||
value: "{{ calibre_enabled }}"
|
value: "{{ calibre_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,14 +19,13 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install Captive Portal if 'captiveportal_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Captive Portal if 'captiveportal_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: captiveportal_installed is undefined
|
when: captiveportal_installed is undefined
|
||||||
|
|
||||||
|
- include_tasks: enable-or-disable.yml
|
||||||
- name: Enable or Disable Captive Portal
|
|
||||||
include_tasks: enable-or-disable.yml
|
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'captiveportal' variable values to {{ iiab_ini_file }}
|
- name: Add 'captiveportal' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
|
@ -43,3 +42,10 @@
|
||||||
value: "{{ captiveportal_install }}"
|
value: "{{ captiveportal_install }}"
|
||||||
- option: captiveportal_enabled
|
- option: captiveportal_enabled
|
||||||
value: "{{ captiveportal_enabled }}"
|
value: "{{ captiveportal_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -1,3 +1,19 @@
|
||||||
|
- name: Enable & Restart 'gitea' systemd service, if gitea_enabled
|
||||||
|
systemd:
|
||||||
|
name: gitea
|
||||||
|
daemon_reload: yes
|
||||||
|
enabled: yes
|
||||||
|
state: restarted
|
||||||
|
when: gitea_enabled
|
||||||
|
|
||||||
|
- name: Disable & Stop 'gitea' systemd service, if not gitea_enabled
|
||||||
|
systemd:
|
||||||
|
name: gitea
|
||||||
|
enabled: no
|
||||||
|
state: stopped
|
||||||
|
when: not gitea_enabled
|
||||||
|
|
||||||
|
|
||||||
- name: Enable http://box{{ gitea_url }} via NGINX, by installing {{ nginx_conf_dir }}/gitea-nginx.conf from template
|
- name: Enable http://box{{ gitea_url }} via NGINX, by installing {{ nginx_conf_dir }}/gitea-nginx.conf from template
|
||||||
template:
|
template:
|
||||||
src: gitea-nginx.conf.j2
|
src: gitea-nginx.conf.j2
|
|
@ -19,29 +19,13 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install Gitea {{ gitea_version }} if 'gitea_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Gitea {{ gitea_version }} if 'gitea_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: gitea_installed is undefined
|
when: gitea_installed is undefined
|
||||||
|
|
||||||
|
- include_tasks: enable-or-disable.yml
|
||||||
- name: Enable & Restart 'gitea' systemd service, if gitea_enabled
|
|
||||||
systemd:
|
|
||||||
name: gitea
|
|
||||||
daemon_reload: yes
|
|
||||||
enabled: yes
|
|
||||||
state: restarted
|
|
||||||
when: gitea_enabled
|
|
||||||
|
|
||||||
- name: Disable & Stop 'gitea' systemd service, if not gitea_enabled
|
|
||||||
systemd:
|
|
||||||
name: gitea
|
|
||||||
enabled: no
|
|
||||||
state: stopped
|
|
||||||
when: not gitea_enabled
|
|
||||||
|
|
||||||
- name: Enable/Disable/Restart NGINX
|
|
||||||
include_tasks: nginx.yml
|
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'gitea' to list of services at {{ iiab_ini_file }}
|
- name: Add 'gitea' to list of services at {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
|
@ -62,3 +46,10 @@
|
||||||
value: "{{ gitea_run_directory }}"
|
value: "{{ gitea_run_directory }}"
|
||||||
- option: gitea_url
|
- option: gitea_url
|
||||||
value: "{{ gitea_url }}"
|
value: "{{ gitea_url }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -1,3 +1,19 @@
|
||||||
|
- name: Enable & Restart 'internetarchive' systemd service, if internetarchive_enabled
|
||||||
|
systemd:
|
||||||
|
name: internetarchive
|
||||||
|
daemon_reload: yes
|
||||||
|
enabled: yes
|
||||||
|
state: restarted
|
||||||
|
when: internetarchive_enabled
|
||||||
|
|
||||||
|
- name: Disable & Stop 'internetarchive' systemd service, if not internetarchive_enabled
|
||||||
|
systemd:
|
||||||
|
name: internetarchive
|
||||||
|
enabled: no
|
||||||
|
state: stopped
|
||||||
|
when: not internetarchive_enabled
|
||||||
|
|
||||||
|
|
||||||
- name: Enable http://box/archive via NGINX, by installing {{ nginx_conf_dir }}/internetarchive-nginx.conf from template
|
- name: Enable http://box/archive via NGINX, by installing {{ nginx_conf_dir }}/internetarchive-nginx.conf from template
|
||||||
template:
|
template:
|
||||||
src: internetarchive-nginx.conf.j2 # TO DO: roles/internetarchive/templates/internetarchive-nginx.conf.j2
|
src: internetarchive-nginx.conf.j2 # TO DO: roles/internetarchive/templates/internetarchive-nginx.conf.j2
|
|
@ -19,8 +19,10 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
# 2020-02-11: @mitra42 & @holta agree (#2247) that the following 2-stanza
|
# 2020-02-11: @mitra42 & @holta agree (#2247) that the following 2-stanza
|
||||||
# "UPDATE internetarchive" block should run whenever one isn't installing
|
# "UPDATE internetarchive" portion should run whenever one isn't installing
|
||||||
# (or reinstalling) internetarchive, for now. We're aware this means slowness
|
# (or reinstalling) internetarchive, for now. We're aware this means slowness
|
||||||
# during "./runrole internetarchive" but that's very intentional for now -- as
|
# during "./runrole internetarchive" but that's very intentional for now -- as
|
||||||
# it leads to more testing of more recent versions of internetarchive, which
|
# it leads to more testing of more recent versions of internetarchive, which
|
||||||
|
@ -29,20 +31,18 @@
|
||||||
# --upgrade internetarchive" or "./runrole --update internetarchive" or such,
|
# --upgrade internetarchive" or "./runrole --update internetarchive" or such,
|
||||||
# as may evolve @ https://github.com/iiab/iiab/pull/2238#discussion_r376168178
|
# as may evolve @ https://github.com/iiab/iiab/pull/2238#discussion_r376168178
|
||||||
|
|
||||||
- block: # BEGIN 2-STANZA BLOCK
|
|
||||||
|
|
||||||
- name: "UPGRADE: Stop 'internetarchive' systemd service, if internetarchive_installed is defined"
|
- name: "UPGRADE: Stop 'internetarchive' systemd service, if internetarchive_installed is defined"
|
||||||
systemd:
|
systemd:
|
||||||
name: internetarchive
|
name: internetarchive
|
||||||
daemon_reload: yes
|
daemon_reload: yes
|
||||||
state: stopped
|
state: stopped
|
||||||
|
when: internetarchive_installed is defined
|
||||||
|
|
||||||
- name: "UPGRADE: Run 'yarn upgrade' in {{ internetarchive_dir }}, if internetarchive_installed is defined"
|
- name: "UPGRADE: Run 'yarn upgrade' in {{ internetarchive_dir }}, if internetarchive_installed is defined"
|
||||||
shell: yarn config set child-concurrency 1 && yarn install && yarn upgrade
|
shell: yarn config set child-concurrency 1 && yarn install && yarn upgrade
|
||||||
args:
|
args:
|
||||||
chdir: "{{ internetarchive_dir }}"
|
chdir: "{{ internetarchive_dir }}"
|
||||||
|
when: internetarchive_installed is defined
|
||||||
when: internetarchive_installed is defined # END 2-STANZA BLOCK
|
|
||||||
|
|
||||||
# "ELSE" INSTALL...
|
# "ELSE" INSTALL...
|
||||||
|
|
||||||
|
@ -51,30 +51,7 @@
|
||||||
when: internetarchive_installed is undefined
|
when: internetarchive_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
# ENABLE/DISABLE/RESTART SYSTEMD SERVICE & WEB SERVERS AS NEC ?
|
- include_tasks: enable-or-disable.yml
|
||||||
|
|
||||||
- name: Enable & Restart 'internetarchive' systemd service, if internetarchive_enabled
|
|
||||||
systemd:
|
|
||||||
name: internetarchive
|
|
||||||
daemon_reload: yes
|
|
||||||
enabled: yes
|
|
||||||
state: restarted
|
|
||||||
when: internetarchive_enabled
|
|
||||||
|
|
||||||
- name: Disable & Stop 'internetarchive' systemd service, if not internetarchive_enabled
|
|
||||||
systemd:
|
|
||||||
name: internetarchive
|
|
||||||
enabled: no
|
|
||||||
state: stopped
|
|
||||||
when: not internetarchive_enabled
|
|
||||||
|
|
||||||
# - name: Enable/Disable/Restart Apache if primary
|
|
||||||
# include_tasks: apache.yml
|
|
||||||
# when: apache_installed is defined and not nginx_enabled
|
|
||||||
|
|
||||||
- name: Enable/Disable/Restart NGINX if primary
|
|
||||||
include_tasks: nginx.yml
|
|
||||||
#when: nginx_enabled
|
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'internetarchive' variable values to {{ iiab_ini_file }}
|
- name: Add 'internetarchive' variable values to {{ iiab_ini_file }}
|
||||||
|
@ -92,3 +69,10 @@
|
||||||
value: "{{ internetarchive_install }}"
|
value: "{{ internetarchive_install }}"
|
||||||
- option: internetarchive_enabled
|
- option: internetarchive_enabled
|
||||||
value: "{{ internetarchive_enabled }}"
|
value: "{{ internetarchive_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,14 +19,14 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install Jupyter if jupyterhub_installed not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Jupyter if jupyterhub_installed not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: jupyterhub_installed is undefined
|
when: jupyterhub_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- include_tasks: enable-or-disable.yml
|
- include_tasks: enable-or-disable.yml
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'jupyterhub' variable values to {{ iiab_ini_file }}
|
- name: Add 'jupyterhub' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
||||||
|
@ -42,3 +42,10 @@
|
||||||
value: "{{ jupyterhub_install }}"
|
value: "{{ jupyterhub_install }}"
|
||||||
- option: jupyterhub_enabled
|
- option: jupyterhub_enabled
|
||||||
value: "{{ jupyterhub_enabled }}"
|
value: "{{ jupyterhub_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
14
roles/kalite/tasks/enable-or-disable.yml
Normal file
14
roles/kalite/tasks/enable-or-disable.yml
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
- name: Enable & (Re)Start 'kalite-serve' service, if kalite_enabled
|
||||||
|
systemd:
|
||||||
|
daemon_reload: yes
|
||||||
|
name: kalite-serve
|
||||||
|
enabled: yes
|
||||||
|
state: restarted
|
||||||
|
when: kalite_enabled
|
||||||
|
|
||||||
|
- name: Disable & Stop 'kalite-serve' service, if not kalite_enabled
|
||||||
|
systemd:
|
||||||
|
name: kalite-serve
|
||||||
|
enabled: no
|
||||||
|
state: stopped
|
||||||
|
when: not kalite_enabled
|
|
@ -19,26 +19,13 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install KA Lite if 'kalite_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install KA Lite if 'kalite_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: kalite_installed is undefined
|
when: kalite_installed is undefined
|
||||||
|
|
||||||
|
- include_tasks: enable-or-disable.yml
|
||||||
- name: Enable & (Re)Start 'kalite-serve' service, if kalite_enabled
|
|
||||||
systemd:
|
|
||||||
daemon_reload: yes
|
|
||||||
name: kalite-serve
|
|
||||||
enabled: yes
|
|
||||||
state: restarted
|
|
||||||
when: kalite_enabled
|
|
||||||
|
|
||||||
- name: Disable & Stop 'kalite-serve' service, if not kalite_enabled
|
|
||||||
systemd:
|
|
||||||
name: kalite-serve
|
|
||||||
enabled: no
|
|
||||||
state: stopped
|
|
||||||
when: not kalite_enabled
|
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'kalite' variable values to {{ iiab_ini_file }}
|
- name: Add 'kalite' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
|
@ -59,3 +46,10 @@
|
||||||
value: "{{ kalite_root }}"
|
value: "{{ kalite_root }}"
|
||||||
- option: port
|
- option: port
|
||||||
value: "{{ kalite_server_port }}"
|
value: "{{ kalite_server_port }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,14 +19,14 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install Kiwix if 'kiwix_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Kiwix if 'kiwix_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: kiwix_installed is undefined
|
when: kiwix_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- include_tasks: enable-or-disable.yml
|
- include_tasks: enable-or-disable.yml
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'kiwix' variable values to {{ iiab_ini_file }}
|
- name: Add 'kiwix' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
path: "{{ iiab_ini_file }}"
|
path: "{{ iiab_ini_file }}"
|
||||||
|
@ -54,3 +54,10 @@
|
||||||
value: "{{ iiab_zim_path }}"
|
value: "{{ iiab_zim_path }}"
|
||||||
- option: kiwix_library_xml
|
- option: kiwix_library_xml
|
||||||
value: "{{ kiwix_library_xml }}"
|
value: "{{ kiwix_library_xml }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,6 +19,8 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
#- name: "Set 'kolibri_provision: False' for a more lightweight (re)install"
|
#- name: "Set 'kolibri_provision: False' for a more lightweight (re)install"
|
||||||
# set_fact:
|
# set_fact:
|
||||||
# kolibri_provision: False
|
# kolibri_provision: False
|
||||||
|
@ -53,3 +55,10 @@
|
||||||
value: "{{ kolibri_exec_path }}"
|
value: "{{ kolibri_exec_path }}"
|
||||||
- option: kolibri_port
|
- option: kolibri_port
|
||||||
value: "{{ kolibri_http_port }}"
|
value: "{{ kolibri_http_port }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,15 +19,15 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install MediaWiki {{ mediawiki_version }} if 'mediawiki_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install MediaWiki {{ mediawiki_version }} if 'mediawiki_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: mediawiki_installed is undefined
|
when: mediawiki_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- name: Enable/Disable/Restart NGINX
|
- name: Enable/Disable/Restart NGINX
|
||||||
include_tasks: nginx.yml
|
include_tasks: nginx.yml
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'mediawiki' variable values to {{ iiab_ini_file }}
|
- name: Add 'mediawiki' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
||||||
|
@ -55,3 +55,10 @@
|
||||||
value: "{{ mediawiki_url }}"
|
value: "{{ mediawiki_url }}"
|
||||||
- option: mediawiki_full_url
|
- option: mediawiki_full_url
|
||||||
value: "{{ mediawiki_full_url }}"
|
value: "{{ mediawiki_full_url }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,14 +19,14 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install Minetest if 'minetest_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Minetest if 'minetest_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: provision.yml # i.e. install.yml in other roles
|
include_tasks: provision.yml # i.e. install.yml in other roles
|
||||||
when: minetest_installed is undefined
|
when: minetest_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- include_tasks: enable-or-disable.yml
|
- include_tasks: enable-or-disable.yml
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'minetest' variable values to {{ iiab_ini_file }}
|
- name: Add 'minetest' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
||||||
|
@ -48,3 +48,10 @@
|
||||||
value: "{{ minetest_port }}"
|
value: "{{ minetest_port }}"
|
||||||
- option: minetest_world_dir
|
- option: minetest_world_dir
|
||||||
value: "{{ minetest_world_dir }}"
|
value: "{{ minetest_world_dir }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
- name: Enable & (Re)Start 'mongodb.service' if mongodb_enabled
|
- name: Enable & (Re)Start 'mongodb.service' if mongodb_enabled
|
||||||
systemd:
|
systemd:
|
||||||
name: mongodb
|
name: mongodb
|
||||||
|
daemon_reload: yes
|
||||||
enabled: yes
|
enabled: yes
|
||||||
state: restarted
|
state: restarted
|
||||||
when: mongodb_enabled
|
when: mongodb_enabled
|
||||||
|
|
|
@ -52,9 +52,8 @@
|
||||||
when: mongodb_installed is undefined
|
when: mongodb_installed is undefined
|
||||||
# when: mongodb_installed is undefined and not (ansible_architecture == "aarch64" and is_debian_10 and not is_raspbian)
|
# when: mongodb_installed is undefined and not (ansible_architecture == "aarch64" and is_debian_10 and not is_raspbian)
|
||||||
|
|
||||||
- name: Enable or Disable MongoDB, if mongodb_installed is defined (sugarizer.service auto-starts MongoDB as nec, so doesn't need this or care what happens here!)
|
- name: Enable or Disable MongoDB (FYI sugarizer.service auto-starts MongoDB as nec, so doesn't need this or care what happens here!)
|
||||||
include_tasks: enable-or-disable.yml
|
include_tasks: enable-or-disable.yml
|
||||||
when: mongodb_installed is defined
|
|
||||||
|
|
||||||
- name: Add 'mongodb' variable values to {{ iiab_ini_file }}
|
- name: Add 'mongodb' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
|
|
|
@ -19,6 +19,8 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
# 2019-07-06: The 'monit' package was suddenly removed from Debian 10.0.0
|
# 2019-07-06: The 'monit' package was suddenly removed from Debian 10.0.0
|
||||||
# "Buster" during the very final days prior to release, as confirmed by the
|
# "Buster" during the very final days prior to release, as confirmed by the
|
||||||
# sudden disappearance of these 2 pages:
|
# sudden disappearance of these 2 pages:
|
||||||
|
@ -59,3 +61,10 @@
|
||||||
value: '"Monit is a background service monitor which can correct problems, send email, restart services."'
|
value: '"Monit is a background service monitor which can correct problems, send email, restart services."'
|
||||||
- option: enabled
|
- option: enabled
|
||||||
value: "{{ monit_enabled }}"
|
value: "{{ monit_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,14 +19,14 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install Mosquitto if 'mosquitto_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Mosquitto if 'mosquitto_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: mosquitto_installed is undefined
|
when: mosquitto_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- include_tasks: enable-or-disable.yml
|
- include_tasks: enable-or-disable.yml
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'mosquitto' variable values to {{ iiab_ini_file }}
|
- name: Add 'mosquitto' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
||||||
|
@ -42,3 +42,10 @@
|
||||||
value: "{{ mosquitto_install }}"
|
value: "{{ mosquitto_install }}"
|
||||||
- option: mosquitto_enabled
|
- option: mosquitto_enabled
|
||||||
value: "{{ mosquitto_enabled }}"
|
value: "{{ mosquitto_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -1,3 +1,19 @@
|
||||||
|
- name: Enable & Start 'munin-node' systemd service
|
||||||
|
systemd:
|
||||||
|
name: munin-node
|
||||||
|
daemon_reload: yes
|
||||||
|
enabled: yes
|
||||||
|
state: started
|
||||||
|
when: munin_enabled
|
||||||
|
|
||||||
|
- name: Disable & Stop 'munin-node' systemd service
|
||||||
|
systemd:
|
||||||
|
name: munin-node
|
||||||
|
enabled: no
|
||||||
|
state: stopped
|
||||||
|
when: not munin_enabled
|
||||||
|
|
||||||
|
|
||||||
- name: Enable http://box/munin via NGINX, by installing {{ nginx_conf_dir }}/munin24-nginx.conf from template
|
- name: Enable http://box/munin via NGINX, by installing {{ nginx_conf_dir }}/munin24-nginx.conf from template
|
||||||
template:
|
template:
|
||||||
src: munin24-nginx.conf.j2
|
src: munin24-nginx.conf.j2
|
|
@ -19,29 +19,13 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install Munin if 'munin_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Munin if 'munin_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: munin_installed is undefined
|
when: munin_installed is undefined
|
||||||
|
|
||||||
|
- include_tasks: enable-or-disable.yml
|
||||||
- name: Enable & Start 'munin-node' systemd service
|
|
||||||
systemd:
|
|
||||||
name: munin-node
|
|
||||||
daemon_reload: yes
|
|
||||||
enabled: yes
|
|
||||||
state: started
|
|
||||||
when: munin_enabled
|
|
||||||
|
|
||||||
- name: Disable & Stop 'munin-node' systemd service
|
|
||||||
systemd:
|
|
||||||
name: munin-node
|
|
||||||
enabled: no
|
|
||||||
state: stopped
|
|
||||||
when: not munin_enabled
|
|
||||||
|
|
||||||
- name: Enable/Disable/Restart NGINX
|
|
||||||
include_tasks: nginx.yml
|
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'munin' variable values to {{ iiab_ini_file }}
|
- name: Add 'munin' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
|
@ -58,3 +42,10 @@
|
||||||
value: "{{ munin_install }}"
|
value: "{{ munin_install }}"
|
||||||
- option: munin_enabled
|
- option: munin_enabled
|
||||||
value: "{{ munin_enabled }}"
|
value: "{{ munin_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,15 +19,15 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install Nextcloud if 'nextcloud_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Nextcloud if 'nextcloud_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: nextcloud_installed is undefined
|
when: nextcloud_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- name: Enable/Disable/Restart NGINX
|
- name: Enable/Disable/Restart NGINX
|
||||||
include_tasks: nginx.yml
|
include_tasks: nginx.yml
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'nextcloud' variable values to {{ iiab_ini_file }}
|
- name: Add 'nextcloud' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
||||||
|
@ -53,3 +53,10 @@
|
||||||
value: "{{ nextcloud_root_dir }}"
|
value: "{{ nextcloud_root_dir }}"
|
||||||
- option: nextcloud_data_dir
|
- option: nextcloud_data_dir
|
||||||
value: "{{ nextcloud_data_dir }}"
|
value: "{{ nextcloud_data_dir }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -35,11 +35,12 @@
|
||||||
var: nodejs_installed
|
var: nodejs_installed
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install Node.js if 'nodejs_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Node.js if 'nodejs_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: nodejs_installed is undefined
|
when: nodejs_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'nodejs' variable values to {{ iiab_ini_file }}
|
- name: Add 'nodejs' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
||||||
|
@ -55,3 +56,10 @@
|
||||||
value: "{{ nodejs_install }}"
|
value: "{{ nodejs_install }}"
|
||||||
- option: nodejs_enabled
|
- option: nodejs_enabled
|
||||||
value: "{{ nodejs_enabled }}"
|
value: "{{ nodejs_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,14 +19,14 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install Node-RED if nodered_installed is not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Node-RED if nodered_installed is not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: nodered_installed is undefined
|
when: nodered_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- include_tasks: enable-or-disable.yml
|
- include_tasks: enable-or-disable.yml
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'nodered' variable values to {{ iiab_ini_file }}
|
- name: Add 'nodered' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
||||||
|
@ -42,3 +42,10 @@
|
||||||
value: "{{ nodered_install }}"
|
value: "{{ nodered_install }}"
|
||||||
- option: nodered_enabled
|
- option: nodered_enabled
|
||||||
value: "{{ nodered_enabled }}"
|
value: "{{ nodered_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -11,15 +11,14 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install OSM Vector Maps if 'osm_vector_maps_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install OSM Vector Maps if 'osm_vector_maps_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: osm_vector_maps_installed is undefined
|
when: osm_vector_maps_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- name: Enable/Disable/Reload NGINX for OSM, if nginx_enabled
|
- name: Enable/Disable/Reload NGINX for OSM, if nginx_enabled
|
||||||
include_tasks: nginx.yml
|
include_tasks: nginx.yml
|
||||||
#when: nginx_enabled # NGINX is mandatory starting with IIAB 7.2
|
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'osm-vector-maps' variable values to {{ iiab_ini_file }}
|
- name: Add 'osm-vector-maps' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
|
@ -36,3 +35,10 @@
|
||||||
value: "{{ osm_vector_maps_install }}"
|
value: "{{ osm_vector_maps_install }}"
|
||||||
- option: osm_vector_maps_enabled
|
- option: osm_vector_maps_enabled
|
||||||
value: "{{ osm_vector_maps_enabled }}"
|
value: "{{ osm_vector_maps_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,6 +19,8 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install PBX if pbx_installed is not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install PBX if pbx_installed is not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: pbx_installed is undefined
|
when: pbx_installed is undefined
|
||||||
|
@ -45,3 +47,10 @@
|
||||||
value: "{{ pbx_install }}"
|
value: "{{ pbx_install }}"
|
||||||
- option: pbx_enabled
|
- option: pbx_enabled
|
||||||
value: "{{ pbx_enabled }}"
|
value: "{{ pbx_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,15 +19,15 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: "INCOMPLETE WITHOUT APACHE AS OF 2021-07-06: Install phpMyAdmin if 'phpmyadmin_installed' not defined, e.g. in {{ iiab_state_file }}" # /etc/iiab/iiab_state.yml
|
- name: "INCOMPLETE WITHOUT APACHE AS OF 2021-07-06: Install phpMyAdmin if 'phpmyadmin_installed' not defined, e.g. in {{ iiab_state_file }}" # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: phpmyadmin_installed is undefined
|
when: phpmyadmin_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- name: INCOMPLETE WITHOUT APACHE AS OF 2021-07-06
|
- name: INCOMPLETE WITHOUT APACHE AS OF 2021-07-06
|
||||||
include_tasks: enable-or-disable.yml
|
include_tasks: enable-or-disable.yml
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'phpmyadmin' variable values to {{ iiab_ini_file }}
|
- name: Add 'phpmyadmin' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
||||||
|
@ -45,3 +45,10 @@
|
||||||
value: "{{ phpmyadmin_enabled }}"
|
value: "{{ phpmyadmin_enabled }}"
|
||||||
- option: path
|
- option: path
|
||||||
value: /opt/phpmyadmin
|
value: /opt/phpmyadmin
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
14
roles/postgresql/tasks/enable-or-disable.yml
Normal file
14
roles/postgresql/tasks/enable-or-disable.yml
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
- name: Enable & Start 'postgresql-iiab' systemd service, if postgresql_enabled
|
||||||
|
systemd:
|
||||||
|
name: postgresql-iiab
|
||||||
|
daemon_reload: yes
|
||||||
|
enabled: yes
|
||||||
|
state: started
|
||||||
|
when: postgresql_enabled
|
||||||
|
|
||||||
|
- name: Disable & Stop 'postgresql-iiab' systemd service, if not postgresql_enabled
|
||||||
|
systemd:
|
||||||
|
name: postgresql-iiab
|
||||||
|
enabled: no
|
||||||
|
state: stopped
|
||||||
|
when: not postgresql_enabled
|
|
@ -26,26 +26,13 @@
|
||||||
var: postgresql_installed
|
var: postgresql_installed
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install PostgreSQL if 'postgresql_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install PostgreSQL if 'postgresql_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: postgresql_installed is undefined
|
when: postgresql_installed is undefined
|
||||||
|
|
||||||
|
- include_tasks: enable-or-disable.yml
|
||||||
- name: Enable & Start 'postgresql-iiab' systemd service, if postgresql_enabled
|
|
||||||
systemd:
|
|
||||||
name: postgresql-iiab
|
|
||||||
daemon_reload: yes
|
|
||||||
enabled: yes
|
|
||||||
state: started
|
|
||||||
when: postgresql_enabled
|
|
||||||
|
|
||||||
- name: Disable & Stop 'postgresql-iiab' systemd service, if not postgresql_enabled
|
|
||||||
systemd:
|
|
||||||
name: postgresql-iiab
|
|
||||||
enabled: no
|
|
||||||
state: stopped
|
|
||||||
when: not postgresql_enabled
|
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'postgresql' variable values to {{ iiab_ini_file }}
|
- name: Add 'postgresql' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
|
@ -62,3 +49,10 @@
|
||||||
value: "{{ postgresql_install }}"
|
value: "{{ postgresql_install }}"
|
||||||
- option: postgresql_enabled
|
- option: postgresql_enabled
|
||||||
value: "{{ postgresql_enabled }}"
|
value: "{{ postgresql_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,14 +19,14 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install Transmission if 'transmission_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install Transmission if 'transmission_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: transmission_installed is undefined
|
when: transmission_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- include_tasks: enable-or-disable.yml
|
- include_tasks: enable-or-disable.yml
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'transmission' variable values to {{ iiab_ini_file }}
|
- name: Add 'transmission' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
||||||
|
@ -65,3 +65,10 @@
|
||||||
# 2020-04-14: better to redact passwords from /etc/iiab/iiab.ini etc, so iiab-diagnostics command doesn't publish these, etc
|
# 2020-04-14: better to redact passwords from /etc/iiab/iiab.ini etc, so iiab-diagnostics command doesn't publish these, etc
|
||||||
#- option: transmission_password
|
#- option: transmission_password
|
||||||
# value: "{{ transmission_password }}"
|
# value: "{{ transmission_password }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -19,14 +19,14 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Install vnStat if 'vnstat_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Install vnStat if 'vnstat_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: install.yml
|
include_tasks: install.yml
|
||||||
when: vnstat_installed is undefined
|
when: vnstat_installed is undefined
|
||||||
|
|
||||||
|
|
||||||
- include_tasks: enable-or-disable.yml
|
- include_tasks: enable-or-disable.yml
|
||||||
|
|
||||||
|
|
||||||
- name: Add 'vnstat' variable values to {{ iiab_ini_file }}
|
- name: Add 'vnstat' variable values to {{ iiab_ini_file }}
|
||||||
ini_file:
|
ini_file:
|
||||||
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
path: "{{ iiab_ini_file }}" # /etc/iiab/iiab.ini
|
||||||
|
@ -42,3 +42,10 @@
|
||||||
value: "{{ vnstat_install }}"
|
value: "{{ vnstat_install }}"
|
||||||
- option: vnstat_enabled
|
- option: vnstat_enabled
|
||||||
value: "{{ vnstat_enabled }}"
|
value: "{{ vnstat_enabled }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
|
@ -21,6 +21,8 @@
|
||||||
quiet: yes
|
quiet: yes
|
||||||
|
|
||||||
|
|
||||||
|
- block:
|
||||||
|
|
||||||
- name: Provision MySQL DB for WordPress, if 'wordpress_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
- name: Provision MySQL DB for WordPress, if 'wordpress_installed' not defined, e.g. in {{ iiab_state_file }} # /etc/iiab/iiab_state.yml
|
||||||
include_tasks: setup.yml
|
include_tasks: setup.yml
|
||||||
when: wordpress_installed is undefined # and not installing
|
when: wordpress_installed is undefined # and not installing
|
||||||
|
@ -61,3 +63,10 @@
|
||||||
value: "{{ wp_url }}"
|
value: "{{ wp_url }}"
|
||||||
- option: wp_full_url
|
- option: wp_full_url
|
||||||
value: "{{ wp_full_url }}"
|
value: "{{ wp_full_url }}"
|
||||||
|
|
||||||
|
rescue:
|
||||||
|
|
||||||
|
- name: 'SEE ERROR ABOVE (skip_role_on_error: {{ skip_role_on_error }})'
|
||||||
|
fail:
|
||||||
|
msg: ""
|
||||||
|
when: not skip_role_on_error
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue