Fix CI for CentOS

Change-Id: I7d8c2b29ece07ead5f6e23706a5e51d4c1b65ad8
This commit is contained in:
Olivier Bourdon 2018-10-03 09:20:11 +02:00
parent 6db1bee4c3
commit 632a5367b1
6 changed files with 20 additions and 3 deletions

View File

@ -139,6 +139,12 @@
recurse: yes
mode: "0755"
- name: ensure parent dir for bm logs has proper rights
file:
state: directory
path: "{{ test_vm_logdir | dirname }}"
mode: "0755"
- name: install virtualbmc
pip:
name: virtualbmc

View File

@ -104,7 +104,7 @@
- name: Setting MySQL socket fact
set_fact:
mysql_socket_path: "/var/run/{% if ansible_distribution | lower is search('suse') %}mysql/mysql.sock{% else %}mysqld/mysqld.sock{% endif %}"
mysql_socket_path: "/var/{% if ansible_os_family | lower == 'redhat' %}lib{% else %}run{% endif %}/{% if ansible_os_family | lower == 'debian' %}mysqld/mysqld.sock{% else %}mysql/mysql.sock{% endif %}"
when: ansible_version.full is version_compare('2.6.5', '>=')
- name: "MySQL - Creating DB"

View File

@ -15,7 +15,7 @@
---
- name: Setting MySQL socket fact
set_fact:
mysql_socket_path: "/var/run/{% if ansible_distribution | lower is search('suse') %}mysql/mysql.sock{% else %}mysqld/mysqld.sock{% endif %}"
mysql_socket_path: "/var/{% if ansible_os_family | lower == 'redhat' %}lib{% else %}run{% endif %}/{% if ansible_os_family | lower == 'debian' %}mysqld/mysqld.sock{% else %}mysql/mysql.sock{% endif %}"
when: ansible_version.full is version_compare('2.6.5', '>=')
- name: "MySQL - Create database"

View File

@ -73,7 +73,7 @@
- name: Setting MySQL socket fact
set_fact:
mysql_socket_path: "/var/run/{% if ansible_distribution | lower is search('suse') %}mysql/mysql.sock{% else %}mysqld/mysqld.sock{% endif %}"
mysql_socket_path: "/var/{% if ansible_os_family | lower == 'redhat' %}lib{% else %}run{% endif %}/{% if ansible_os_family | lower == 'debian' %}mysqld/mysqld.sock{% else %}mysql/mysql.sock{% endif %}"
when: ansible_version.full is version_compare('2.6.5', '>=')
- name: "MySQL - Creating DB"

View File

@ -37,10 +37,12 @@ if $(journalctl --version &>/dev/null); then
sudo journalctl -u ironic-api &> ${LOG_LOCATION}/ironic-api.log
sudo journalctl -u ironic-conductor &> ${LOG_LOCATION}/ironic-conductor.log
sudo journalctl -u ironic-inspector &> ${LOG_LOCATION}/ironic-inspector.log
sudo journalctl -u libvirtd &> ${LOG_LOCATION}/libvirtd.log
else
sudo cp /var/log/upstart/ironic-api.log ${LOG_LOCATION}/
sudo cp /var/log/upstart/ironic-conductor.log ${LOG_LOCATION}/
sudo cp /var/log/upstart/ironic-inspector.log ${LOG_LOCATION}/
sudo cp /var/log/upstart/libvirtd.log ${LOG_LOCATION}/
fi
# Copy PXE information
@ -58,6 +60,10 @@ if [ -d "/var/log/ironic" ]; then
cp -a "/var/log/ironic" ${LOG_LOCATION}/ipa-logs
fi
sudo vbmc list &> ${LOG_LOCATION}/vbmc.txt
sudo virsh list --all &> ${LOG_LOCATION}/virsh-list.txt
ps auxf &> ${LOG_LOCATION}/ps.txt
sudo chown -R $USER ${LOG_LOCATION}
# In CI scenarios, we want other users to be able to read the logs.
sudo chmod -R o+r ${LOG_LOCATION}

View File

@ -184,6 +184,11 @@ sudo -H -E ${PIP} install "pip>6.0"
# upgrade setuptools, as latest version is needed to install some projects
sudo -H -E ${PIP} install --upgrade --force setuptools
if [ "$OS_FAMILY" == "RedHat" ]; then
sudo -H -E ${PIP} freeze
sudo -H -E ${PIP} install --ignore-installed pyparsing ipaddress
fi
sudo -H -E ${PIP} install -r "$(dirname $0)/../requirements.txt"
# Install the rest of required packages using bindep