diff options
author | Samuli Silvius <s.silvius@partner.samsung.com> | 2019-02-05 09:45:24 +0200 |
---|---|---|
committer | Samuli Silvius <s.silvius@partner.samsung.com> | 2019-02-12 09:37:14 +0200 |
commit | fe111116be4128a9fb90d175c38e0aa955e7e33f (patch) | |
tree | 37bc4f9830c5f9c68a5386e31dbc6056e77074e5 /ansible/roles | |
parent | 6e5b45ab81ee9bfba2a396b65ffdd999abffc4e4 (diff) |
Helm install optional and default values
Make Helm applicaton installation optional by allowing
user not to provide Helm charts. Then only empty Kubernetes
cluster will be installed.
Provide some reasonable default values for Helm charts
configuration variables both in package script and ansible
installer itself. User provided Helm charts configuration
must be in sync with packaging and installer, provided
some clarifying comments for that.
Issue-ID: OOM-1629
Change-Id: Ica9fc76856cb50c9d636bea99a326736736c7a56
Signed-off-by: Samuli Silvius <s.silvius@partner.samsung.com>
Diffstat (limited to 'ansible/roles')
-rw-r--r-- | ansible/roles/application-install/tasks/main.yml | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/ansible/roles/application-install/tasks/main.yml b/ansible/roles/application-install/tasks/main.yml index 3306d9e4..89e7ef7e 100644 --- a/ansible/roles/application-install/tasks/main.yml +++ b/ansible/roles/application-install/tasks/main.yml @@ -2,4 +2,21 @@ - debug: msg: "phase is {{ phase }}" +- name: Check if install needed + block: + - name: "Does {{ app_helm_charts_install_directory }} exist and contain Helm Charts" + find: + paths: "{{ app_helm_charts_install_directory }}" + recurse: yes + delegate_to: localhost + register: charts_files + - name: Set install active fact + set_fact: + install_needed: "{{ yes if charts_files.matched | int > 0 else no }}" + when: phase == "pre-install" + - include_tasks: "{{ phase }}.yml" + when: install_needed + +- debug: + msg: "Install needed {{ install_needed }}" |