Fix $TARGET_ROOT usage in yum element
Fix the test for $TARGET_ROOT in root.d/50-yum-cache. Don't use $TARGET_ROOT in pre-install, it's only set for "root" and "cleanup". Change-Id: I048364ea08ef503a4466f3494f18f72ebf99b5c2
This commit is contained in:
parent
31ff8235a3
commit
ba5aa8725e
2 changed files with 3 additions and 5 deletions
|
@ -2,7 +2,5 @@
|
|||
|
||||
set -e
|
||||
|
||||
[ -n "TARGET_ROOT" ]
|
||||
|
||||
sudo sed -i 's/keepcache=0/keepcache=1/' $TARGET_ROOT/etc/yum.conf
|
||||
sudo sed -i 's/cachedir=\/var\/cache\/yum/cachedir=\/tmp\/yum/' $TARGET_ROOT/etc/yum.conf
|
||||
sudo sed -i 's/keepcache=0/keepcache=1/' /etc/yum.conf
|
||||
sudo sed -i 's/cachedir=\/var\/cache\/yum/cachedir=\/tmp\/yum/' /etc/yum.conf
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
set -e
|
||||
|
||||
[ -n "TARGET_ROOT" ]
|
||||
[ -n "$TARGET_ROOT" ]
|
||||
|
||||
YUM_CACHE_DIR=~/.cache/image-create/yum
|
||||
mkdir -p $YUM_CACHE_DIR
|
||||
|
|
Loading…
Reference in a new issue