From 0681b75c39a255e679fd0c612ab8ba103d2ca8b0 Mon Sep 17 00:00:00 2001 From: Emilien Macchi Date: Tue, 12 Apr 2016 08:32:53 -0400 Subject: [PATCH] run_tests: strip locale archive to en_* locales This is a workaround until https://review.openstack.org/#/c/304399/ will be merged and a new image will be built and uploaded to OpenStack Infra Clouds. Until then, we'll carry this code so we can move forward with Puppet4 testing and deploy Facter correctly. Change-Id: I823087aed543c3cf43d247f7adf5f32c5c0fc31e --- run_tests.sh | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/run_tests.sh b/run_tests.sh index 20d227d2a..d61b51824 100755 --- a/run_tests.sh +++ b/run_tests.sh @@ -69,6 +69,20 @@ if uses_debs; then $SUDO apt-get update $SUDO apt-get install -y dstat ${PUPPET_PKG} elif is_fedora; then + # TODO(emilien): this is a workaround until this patch is merged: + # https://review.openstack.org/#/c/304399/ + # strip down to en_* locales + $SUDO yum reinstall -y glibc-common glibc + $SUDO localedef --delete-from-archive \ + $(localedef --list-archive | grep -v -i '^en' | xargs) + # prepare template + $SUDO mv /usr/lib/locale/locale-archive /usr/lib/locale/locale-archive.tmpl + # rebuild archive + $SUDO /usr/sbin/build-locale-archive + # empty template + $SUDO mkdir -p /usr/locale + echo | $SUDO tee --append /usr/locale/locale-archive.tmpl + if rpm --quiet -q $PUPPET_RELEASE_FILE; then $SUDO rpm -e $PUPPET_RELEASE_FILE fi