From eaf4a782fb3dc672180ac9551e00e02624057223 Mon Sep 17 00:00:00 2001 From: Markos Chandras Date: Thu, 28 Sep 2017 08:01:45 +0100 Subject: xci: configure-opnfvhost: Do not check /etc/ssl/certs on SUSE This is similar to Ibc188b76f47c4f7d1c5aa452a21e838420d65e6a /etc/ssl/certs is a symlink so skip this task on SUSE. Change-Id: Iae38640501748dc3dd802ce795acfaeefd836c97 Signed-off-by: Markos Chandras --- xci/playbooks/configure-opnfvhost.yml | 1 + 1 file changed, 1 insertion(+) (limited to 'xci') diff --git a/xci/playbooks/configure-opnfvhost.yml b/xci/playbooks/configure-opnfvhost.yml index 7b16c5aa..73516d5a 100644 --- a/xci/playbooks/configure-opnfvhost.yml +++ b/xci/playbooks/configure-opnfvhost.yml @@ -123,6 +123,7 @@ file: path: "/etc/ssl/certs" state: directory + when: ansible_pkg_mgr != 'zypper' - name: create key directory /etc/ssl/private file: path: "/etc/ssl/private" -- cgit 1.2.3-korg From 4b979090960ba44e64695e8b9b5dc3ef275e9dd0 Mon Sep 17 00:00:00 2001 From: Markos Chandras Date: Thu, 28 Sep 2017 08:15:41 +0100 Subject: xci: scripts: build-dib-os.sh: Pin diskimage-builder diskimage-builder does very frequent releases and sometimes things break. There is no particular reason to always fetch the latest version so lets do it in a controlled way after proper testing. Change-Id: Ie9685a9a15fa7fefa1c5ecea49090ac9d92e63ff Signed-off-by: Markos Chandras --- xci/scripts/vm/build-dib-os.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'xci') diff --git a/xci/scripts/vm/build-dib-os.sh b/xci/scripts/vm/build-dib-os.sh index 78eaff2d..a09ee3c6 100755 --- a/xci/scripts/vm/build-dib-os.sh +++ b/xci/scripts/vm/build-dib-os.sh @@ -36,7 +36,7 @@ sudo apt-get install -y -q=3 yum yum-utils rpm zypper kpartx python-pip debootst echo "Installing diskimage-builder" -sudo -H pip install -q -U diskimage-builder +sudo -H pip install -q diskimage-builder==2.9.0 echo "Removing old files..." sudo rm -rf *.qcow2 *.sha256.txt -- cgit 1.2.3-korg From 635b13830c4d01a5ea153aec9f79b55e059bb8b0 Mon Sep 17 00:00:00 2001 From: Markos Chandras Date: Tue, 26 Sep 2017 09:08:08 +0100 Subject: xci: configure-opnfvhost: Do not run 'remove-folders' The OPNFV node is brand new and it doesn't have any traces of XCI directories so there is no point in running the 'remove-folders' role. Change-Id: Ic9b9203cc14abda2dab406de6a5feeef6a1b7e2a Signed-off-by: Markos Chandras --- xci/file/aio/configure-opnfvhost.yml | 9 --------- xci/playbooks/configure-opnfvhost.yml | 13 ------------- 2 files changed, 22 deletions(-) (limited to 'xci') diff --git a/xci/file/aio/configure-opnfvhost.yml b/xci/file/aio/configure-opnfvhost.yml index 535b14dc..f25476f9 100644 --- a/xci/file/aio/configure-opnfvhost.yml +++ b/xci/file/aio/configure-opnfvhost.yml @@ -1,13 +1,4 @@ --- -- hosts: opnfv - remote_user: root - gather_facts: true - become: yes - vars_files: - - ../var/opnfv.yml - roles: - - role: remove-folders - - hosts: opnfv remote_user: root vars_files: diff --git a/xci/playbooks/configure-opnfvhost.yml b/xci/playbooks/configure-opnfvhost.yml index 73516d5a..173a29eb 100644 --- a/xci/playbooks/configure-opnfvhost.yml +++ b/xci/playbooks/configure-opnfvhost.yml @@ -7,19 +7,6 @@ # which accompanies this distribution, and is available at # http://www.apache.org/licenses/LICENSE-2.0 ############################################################################## -- hosts: opnfv - remote_user: root - become: yes - vars_files: - - ../var/flavor-vars.yml - - ../var/opnfv.yml - pre_tasks: - - name: Load distribution variables - include_vars: - file: ../var/{{ ansible_os_family }}.yml - roles: - - role: remove-folders - - hosts: opnfv remote_user: root vars_files: -- cgit 1.2.3-korg From c55729a3077954bcfe54fee01b0923918fbb7889 Mon Sep 17 00:00:00 2001 From: Markos Chandras Date: Thu, 28 Sep 2017 09:31:54 +0100 Subject: xci: playbooks: synchronize-time: Fix service name for openSUSE In openSUSE, the chrony service is 'chronyd'. Change-Id: Ifb946b0ba49783108a84dd5b998d9d45f5c9df51 Signed-off-by: Markos Chandras --- xci/playbooks/roles/synchronize-time/tasks/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'xci') diff --git a/xci/playbooks/roles/synchronize-time/tasks/main.yml b/xci/playbooks/roles/synchronize-time/tasks/main.yml index cc73c447..8f94d33f 100644 --- a/xci/playbooks/roles/synchronize-time/tasks/main.yml +++ b/xci/playbooks/roles/synchronize-time/tasks/main.yml @@ -13,7 +13,7 @@ state: latest - name: restart chrony service: - name: chrony + name: "{{ (ansible_pkg_mgr == 'apt') | ternary('chrony', 'chronyd') }}" state: restarted - name: synchronize time shell: "chronyc -a 'burst 4/4' && chronyc -a makestep" -- cgit 1.2.3-korg From 4e376686a539fa08cd0873de6a036f0a096a0066 Mon Sep 17 00:00:00 2001 From: Markos Chandras Date: Thu, 28 Sep 2017 14:22:34 +0100 Subject: xci: xci-deploy.sh: Apply workaround for checking db cluster on SUSE The mysql socket path is wrong on SUSE which leads to problems when trying to verify the status of the db cluster. Apply workaround until it's fixed upstream controller00_galera_container-56c89184 | FAILED | rc=1 >> ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2 "No such file or directory") Change-Id: I23192f4079526ae7820a1db023a097a651a09140 Link: https://review.openstack.org/508154 Signed-off-by: Markos Chandras --- xci/xci-deploy.sh | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'xci') diff --git a/xci/xci-deploy.sh b/xci/xci-deploy.sh index 80ff53b6..fd3849be 100755 --- a/xci/xci-deploy.sh +++ b/xci/xci-deploy.sh @@ -250,6 +250,13 @@ fi #------------------------------------------------------------------------------- echo "Info: Verifying database cluster" echo "-----------------------------------------------------------------------" +# Apply SUSE fix until https://review.openstack.org/508154 is merged +if [[ ${OS_FAMILY,,} == "suse" ]]; then + ssh root@$OPNFV_HOST_IP "ansible --ssh-extra-args='-o StrictHostKeyChecking=no' \ + -i $OPENSTACK_OSA_PATH/playbooks/inventory/ galera_container -m shell \ + -a \"sed -i \\\"s@/var/run/mysqld/mysqld.sock@/var/run/mysql/mysql.sock@\\\" /etc/my.cnf\"" +fi + ssh root@$OPNFV_HOST_IP "ansible --ssh-extra-args='-o StrictHostKeyChecking=no' \ -i $OPENSTACK_OSA_PATH/playbooks/inventory/ galera_container -m shell \ -a \"mysql -h localhost -e \\\"show status like '%wsrep_cluster_%';\\\"\" | tee galera.log" -- cgit 1.2.3-korg