From 80706ed6e3505605de41fad308df85c6166b98f8 Mon Sep 17 00:00:00 2001 From: Samuel Cassiba Date: Thu, 17 May 2018 22:23:41 -0700 Subject: [PATCH] Add contentdir yum variable The centos-release-qemu-ev repo package now supports $contentdir but CentOS base has not fully caught up yet.[0] [0] https://lists.centos.org/pipermail/centos-devel/2018-March/016542.html Change-Id: I9e530b89092e0d4abb14750d4c181a7712c94e8c --- recipes/default.rb | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/recipes/default.rb b/recipes/default.rb index 11343478..6b5739ee 100644 --- a/recipes/default.rb +++ b/recipes/default.rb @@ -110,6 +110,16 @@ when 'rhel' action deps_action end + # TODO(sc): workaround to add $contentdir + # removable when centos is updated + bash 'yum_contentdir' do + cwd ::File.dirname('/etc/yum/vars') + code <<-EOH + echo 'centos' > /etc/yum/vars/contentdir + EOH + not_if { ::File.exist?('/etc/yum/vars/contentdir') } + end + package 'centos-release-qemu-ev' do action :upgrade end