diff --git a/roles/pbx/tasks/main.yml b/roles/pbx/tasks/main.yml index 2ee162686..da4810761 100644 --- a/roles/pbx/tasks/main.yml +++ b/roles/pbx/tasks/main.yml @@ -1,9 +1,17 @@ +- name: Throw warning if sugarizer_install is true + debug: Refusing to install as sugarizer_install is true. Fix that and rerun. + when: pbx_install and sugarizer_install + +- name: Throw warning if sugarizer_install is true + debug: Refusing to install as nodejs_version is not 10.x. Fix that and rerun. + when: pbx_install and (nodejs_version != "10.x") + #- name: TODO: Check if asterisk and freepbx are already installed - name: Install asterisk include_tasks: asterisk.yml - when: internet_available and is_ubuntu_18 and pbx_install and (not pbx_installed) + when: internet_available and is_ubuntu_18 and pbx_install and (not pbx_installed) and (not sugarizer_install) and (nodejs_version == "10.x") - name: Install freepbx include_tasks: freepbx.yml - when: internet_available and is_ubuntu_18 and pbx_install and (not pbx_installed) + when: internet_available and is_ubuntu_18 and pbx_install and (not pbx_installed) and (not sugarizer_install) and (nodejs_version == "10.x")