diff options
author | Bryan McLellan <btm@loftninjas.org> | 2019-04-16 11:45:20 -0400 |
---|---|---|
committer | Bryan McLellan <btm@loftninjas.org> | 2019-04-16 12:09:36 -0400 |
commit | c248a1e9f7e5ef3c7d832c422ea887cb2841f101 (patch) | |
tree | 50a3a240dbf8081f9b182ff265121306a2bae169 /kitchen-tests | |
parent | 7f62eff6d676365c9e1a984728e9b02bbd74d3ae (diff) | |
download | chef-c248a1e9f7e5ef3c7d832c422ea887cb2841f101.tar.gz |
disable yum metadata caching for end-to-end centos/rhel tests
Signed-off-by: Bryan McLellan <btm@loftninjas.org>
Diffstat (limited to 'kitchen-tests')
-rw-r--r-- | kitchen-tests/cookbooks/end_to_end/recipes/default.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/kitchen-tests/cookbooks/end_to_end/recipes/default.rb b/kitchen-tests/cookbooks/end_to_end/recipes/default.rb index 7c9856d909..6d95f4471b 100644 --- a/kitchen-tests/cookbooks/end_to_end/recipes/default.rb +++ b/kitchen-tests/cookbooks/end_to_end/recipes/default.rb @@ -17,6 +17,13 @@ if platform_family?("rhel", "fedora", "amazon") include_recipe "selinux::disabled" end +bash "disable yum metadata caching" do + code <<-EOH + echo http_caching=packages >> /etc/yum.conf + EOH + only_if { File.exist?("/etc/yum.conf") && File.readlines("/etc/yum.conf").grep(/http_caching=packages/).empty? } +end + yum_repository "epel" do enabled true description "Extra Packages for Enterprise Linux #{node['platform_version'].to_i} - $basearch" |