summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarkos Chandras <mchandras@suse.de>2018-06-01 09:51:53 +0000
committerGerrit Code Review <gerrit@opnfv.org>2018-06-01 09:51:53 +0000
commit9d9d9a4d6031fe795b8d3dbd71250f676a4180d4 (patch)
treedfd85a8c24c6b344a8adc570eea9c2cce45a26aa
parente081553a506a57d238bb3f1691abcae46175f99a (diff)
parentc5e7e23fadc2738985ac6b3e585edd9918f6494b (diff)
Merge "xci: kubespray: Use bootstrap role for k8s deployments"
-rw-r--r--xci/installer/kubespray/playbooks/configure-opnfvhost.yml7
-rw-r--r--xci/installer/kubespray/playbooks/configure-targethosts.yml13
l---------xci/playbooks/roles/bootstrap-host/templates/kubespray1
3 files changed, 20 insertions, 1 deletions
diff --git a/xci/installer/kubespray/playbooks/configure-opnfvhost.yml b/xci/installer/kubespray/playbooks/configure-opnfvhost.yml
index c6b29dc0..00a8053f 100644
--- a/xci/installer/kubespray/playbooks/configure-opnfvhost.yml
+++ b/xci/installer/kubespray/playbooks/configure-opnfvhost.yml
@@ -11,7 +11,7 @@
vars_files:
- "{{ xci_path }}/xci/var/opnfv.yml"
- tasks:
+ pre_tasks:
- name: Load distribution variables
include_vars:
file: "{{ item }}"
@@ -23,6 +23,11 @@
remote_xci_flavor_files: "{{ ansible_env.HOME }}/releng-xci/xci/installer/{{ installer_type }}/files/{{ xci_flavor }}"
remote_xci_playbooks: "{{ ansible_env.HOME }}/releng-xci/xci/playbooks"
+ roles:
+ - role: bootstrap-host
+ configure_network: xci_flavor != 'aio'
+
+ tasks:
- name: Copy releng-xci to remote host
synchronize:
src: "{{ xci_path }}/"
diff --git a/xci/installer/kubespray/playbooks/configure-targethosts.yml b/xci/installer/kubespray/playbooks/configure-targethosts.yml
index c744eae6..7989bfb6 100644
--- a/xci/installer/kubespray/playbooks/configure-targethosts.yml
+++ b/xci/installer/kubespray/playbooks/configure-targethosts.yml
@@ -1,6 +1,19 @@
---
- hosts: k8s-cluster
remote_user: root
+ vars_files:
+ - "{{ xci_path }}/xci/var/opnfv.yml"
+
+ pre_tasks:
+ - name: Load distribution variables
+ include_vars:
+ file: "{{ item }}"
+ with_items:
+ - "{{ xci_path }}/xci/var/{{ ansible_os_family }}.yml"
+
+ roles:
+ - role: bootstrap-host
+
tasks:
- name: Manage SSH keys
include_tasks: "{{ xci_path }}/xci/playbooks/manage-ssh-keys.yml"
diff --git a/xci/playbooks/roles/bootstrap-host/templates/kubespray b/xci/playbooks/roles/bootstrap-host/templates/kubespray
new file mode 120000
index 00000000..f820fd11
--- /dev/null
+++ b/xci/playbooks/roles/bootstrap-host/templates/kubespray
@@ -0,0 +1 @@
+osa \ No newline at end of file