2021-08-04 01:10:34 +00:00
- name : "ONLY PHP 7.4 IS SUPPORTED AS OF AUG 2021 -- PLEASE READ: https://github.com/iiab/iiab/tree/master/roles/pbx/#pbx-readme"
meta : noop
2021-07-27 12:41:22 +00:00
2020-02-04 20:03:59 +00:00
- name : "Set 'nodejs_install: True' and 'nodejs_enabled: True'"
set_fact :
nodejs_install : True
nodejs_enabled : True
- name : NODEJS - run 'nodejs' role (attempt to install & enable Node.js)
include_role :
name : nodejs
- name : FAIL (STOP THE INSTALL) IF 'nodejs_installed is undefined'
fail :
msg : "PBX install cannot proceed, as Node.js is not installed."
when : nodejs_installed is undefined
2020-11-14 19:14:06 +00:00
#- name: FAIL (STOP THE INSTALL) IF 'nodejs_version != "12.x"'
# fail:
# msg: "PBX install cannot proceed, as it currently requires Node.js 12.x, whereas nodejs_version is set to {{ nodejs_version }}. Please check the value of nodejs_version in /opt/iiab/iiab/vars/default_vars.yml, /etc/iiab/local_vars.yml, /opt/iiab/iiab/roles/nodejs, etc."
# when: nodejs_version != "12.x"
2020-02-04 20:03:59 +00:00
2021-07-27 12:41:22 +00:00
2020-08-24 06:35:33 +00:00
- name : "Set 'apache_install: True' and 'apache_enabled: True'"
set_fact :
apache_install : True
apache_enabled : True
- name : APACHE - run 'httpd' role
include_role :
name : httpd
2020-02-04 20:03:59 +00:00
2021-08-05 04:16:56 +00:00
#- name: Install Asterisk
# include_tasks: asterisk.yml
2020-02-04 20:03:59 +00:00
2021-07-27 12:41:22 +00:00
- name : Install FreePBX
2020-02-04 20:03:59 +00:00
include_tasks : freepbx.yml
# RECORD PBX AS INSTALLED
- name : "Set 'pbx_installed: True'"
set_fact :
pbx_installed : True
- name : "Add 'pbx_installed: True' to {{ iiab_state_file }}"
lineinfile :
path : "{{ iiab_state_file }}" # /etc/iiab/iiab_state.yml
regexp : '^pbx_installed'
line: 'pbx_installed : True '