summaryrefslogtreecommitdiffstats
path: root/roles/ands_kaas
diff options
context:
space:
mode:
authorSuren A. Chilingaryan <csa@suren.me>2018-03-22 04:37:46 +0100
committerSuren A. Chilingaryan <csa@suren.me>2018-03-22 04:37:46 +0100
commit0b0b9954c2d0602b1e9d0a387d2a195a790f8084 (patch)
treef0a3a26edd280b8fd84945944bd153f411b31fea /roles/ands_kaas
parente2c7b1305ca8495065dcf40fd2092d7c698dd6ea (diff)
downloadands-0b0b9954c2d0602b1e9d0a387d2a195a790f8084.tar.gz
ands-0b0b9954c2d0602b1e9d0a387d2a195a790f8084.tar.bz2
ands-0b0b9954c2d0602b1e9d0a387d2a195a790f8084.tar.xz
ands-0b0b9954c2d0602b1e9d0a387d2a195a790f8084.zip
Various fixes and provide ADEI admin container...
Diffstat (limited to 'roles/ands_kaas')
-rw-r--r--roles/ands_kaas/tasks/do_apps.yml2
-rw-r--r--roles/ands_kaas/tasks/do_storage.yml4
-rw-r--r--roles/ands_kaas/tasks/project.yml2
-rw-r--r--roles/ands_kaas/tasks/template.yml4
4 files changed, 6 insertions, 6 deletions
diff --git a/roles/ands_kaas/tasks/do_apps.yml b/roles/ands_kaas/tasks/do_apps.yml
index 39283b4..0e49981 100644
--- a/roles/ands_kaas/tasks/do_apps.yml
+++ b/roles/ands_kaas/tasks/do_apps.yml
@@ -1,7 +1,7 @@
- name: "Process KaaS apps"
include_tasks: "template.yml"
run_once: true
- with_dict: "{{ kaas_project_apps }}"
+ with_dict: "{{ kaas_project_apps | default({}) }}"
loop_control:
loop_var: appitem
when:
diff --git a/roles/ands_kaas/tasks/do_storage.yml b/roles/ands_kaas/tasks/do_storage.yml
index e79db56..8a6a880 100644
--- a/roles/ands_kaas/tasks/do_storage.yml
+++ b/roles/ands_kaas/tasks/do_storage.yml
@@ -18,7 +18,7 @@
volume: "{{osv.value}}"
when:
- ( mntpath | length ) > 0
- - (kaas_storage_types is not defined) or ((osv.type | default("host")) in kaas_storage_types)
+ - (kaas_storage_types is not defined) or (voltype in kaas_storage_types)
- name: Check if static configuration exists
local_action: stat path="{{ kaas_project_path }}/files/"
@@ -50,4 +50,4 @@
hostpath: "{{ hostvars[inventory_hostname][hvar] }}/{{ file.path }}"
when:
- file.osv in kaas_project_volumes
- - (kaas_storage_types is not defined) or ((osv.type | default("host")) in kaas_storage_types)
+ - (kaas_storage_types is not defined) or (voltype in kaas_storage_types)
diff --git a/roles/ands_kaas/tasks/project.yml b/roles/ands_kaas/tasks/project.yml
index 26bd0cc..879f34a 100644
--- a/roles/ands_kaas/tasks/project.yml
+++ b/roles/ands_kaas/tasks/project.yml
@@ -59,7 +59,7 @@
kaas_project_volumes: "{{ kaas_project_config.volumes | default(kaas_project_config.extra_volumes | default({}) | combine(kaas_openshift_volumes)) }}"
kaas_project_local_volumes: "{{ kaas_project_config.local_volumes | default({}) }}"
kaas_project_pods: "{{ kaas_project_config.pods | default({}) }}"
- kaas_project_apps: "{{ kaas_project_config.apps | default([]) }}"
+ kaas_project_apps: "{{ kaas_project_config.apps | default({}) }}"
kaas_project_gids: "{{ kaas_project_config.gids | default(kaas_openshift_gids) }}"
kaas_project_uids: "{{ kaas_project_config.uids | default(kaas_openshift_uids) }}"
kaas_blockvol_info: "{{ block_info }}"
diff --git a/roles/ands_kaas/tasks/template.yml b/roles/ands_kaas/tasks/template.yml
index 87e45a6..841c80e 100644
--- a/roles/ands_kaas/tasks/template.yml
+++ b/roles/ands_kaas/tasks/template.yml
@@ -20,8 +20,8 @@
template: "{{ dest_name }}"
template_path: "{{ kaas_template_path }}"
project: "{{ kaas_project }}"
- recreate: "{{ result | changed | ternary (delete | ternary(true, false), false) }}"
- replace: "{{ result | changed | ternary (delete | ternary(false, true), false) }}"
+ recreate: "{{ result | changed | ternary (delete | default(true) | ternary(true, false), false) }}"
+ replace: "{{ result | changed | ternary (delete | default(true) | ternary(false, true), false) }}"
# alternatively load template
# TODO