diskimage-builder/elements/yum/post-install.d/99-reset-yum-conf
James Slagle 8175a7ef4d Reset yum configuration in post-install.d
When using the yum element, we should reset the changes we've made to
/etc/yum.conf during post-install.d. Otherwise, this build time
configuration is propagated into booted instances.

Change-Id: I1eea586ca0fefe9bc0cf91fedefcbd141a536fa2
2014-09-11 20:59:50 -04:00

7 lines
172 B
Bash
Executable file

#!/bin/bash
set -eux
set -o pipefail
sudo sed -i 's/keepcache=1/keepcache=0/' /etc/yum.conf
sudo sed -i 's/cachedir=\/tmp\/yum/cachedir=\/var\/cache\/yum/' /etc/yum.conf