summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarkos Chandras <mchandras@suse.de>2018-04-06 09:16:57 +0000
committerGerrit Code Review <gerrit@opnfv.org>2018-04-06 09:16:57 +0000
commite5674e0a504304c3ac698cca39b93e8c4992b067 (patch)
treefd50b359a5656ebb7da2ba5733c8c34da036197e
parentc7265ea52861b7d8e6d784f611ac43424fd5a855 (diff)
parent3d521b01d4e569b52f22ecffa05b834c444f1dea (diff)
Merge "xci: kubespray: Fix failures to due task checks"
-rwxr-xr-xxci/installer/kubespray/deploy.sh6
-rw-r--r--xci/installer/kubespray/playbooks/configure-opnfvhost.yml5
2 files changed, 6 insertions, 5 deletions
diff --git a/xci/installer/kubespray/deploy.sh b/xci/installer/kubespray/deploy.sh
index 364ee2b6..5136f5a8 100755
--- a/xci/installer/kubespray/deploy.sh
+++ b/xci/installer/kubespray/deploy.sh
@@ -91,10 +91,12 @@ echo "-----------------------------------------------------------------------"
echo "Info: Kubernetes installation is successfully completed!"
echo "-----------------------------------------------------------------------"
-# Configure the kubernetes authentication in opnfv host.
+# Configure the kubernetes authentication in opnfv host. In future releases
+# kubectl is no longer an artifact so we should not fail if it's not available.
+# This needs to be removed in the future
ssh root@$OPNFV_HOST_IP "mkdir -p ~/.kube/;\
cp -f ~/admin.conf ~/.kube/config; \
- cp -f ~/kubectl /usr/local/bin"
+ cp -f ~/kubectl /usr/local/bin || true"
echo "Login opnfv host ssh root@$OPNFV_HOST_IP
according to the user-guide to create a service
diff --git a/xci/installer/kubespray/playbooks/configure-opnfvhost.yml b/xci/installer/kubespray/playbooks/configure-opnfvhost.yml
index eed814ba..a4bdbf07 100644
--- a/xci/installer/kubespray/playbooks/configure-opnfvhost.yml
+++ b/xci/installer/kubespray/playbooks/configure-opnfvhost.yml
@@ -59,7 +59,7 @@
command: "cp -rf {{ remote_xci_path }}/xci/installer/kubespray/files/k8s-cluster.yml \
{{ remote_xci_path }}/.cache/repos/kubespray/opnfv_inventory/group_vars"
args:
- creates: "{{ remote_xci_path }}/.cache/repos/kubespray/opnfv_inventory/group_vars"
+ creates: "{{ remote_xci_path }}/.cache/repos/kubespray/opnfv_inventory/group_vars/k8s-cluster.yml"
- name: Install required packages
package:
name: "{{ kube_require_packages[ansible_pkg_mgr] }}"
@@ -86,5 +86,4 @@
tasks:
- name: Append public keys to authorized_keys
shell: "/bin/cat {{ ansible_env.HOME }}/.ssh/id_rsa.pub >> {{ xci_path }}/xci/files/authorized_keys"
- args:
- creates: "{{ xci_path }}/xci/files/authorized_keys"
+ changed_when: True