From 2987294ea6afc9939dc103467232fa290450853e Mon Sep 17 00:00:00 2001 From: clayton craft Date: Fri, 3 Nov 2017 19:19:23 -0700 Subject: [PATCH] Remove existing apk cache symlink before creating link (#866) This removes any existing symlinks (which always seem to be broken when this is encountered) to /chroot_native/etc/apk/cache before creating the symlink. --- pmb/chroot/init.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pmb/chroot/init.py b/pmb/chroot/init.py index 3b7ac84d..2e907ab8 100644 --- a/pmb/chroot/init.py +++ b/pmb/chroot/init.py @@ -72,7 +72,7 @@ def init(args, suffix="native"): # Initialize cache apk_cache = args.work + "/cache_apk_" + arch - pmb.helpers.run.root(args, ["ln", "-s", "/var/cache/apk", chroot + + pmb.helpers.run.root(args, ["ln", "-s", "-f", "/var/cache/apk", chroot + "/etc/apk/cache"]) # Initialize /etc/apk/keys/, resolv.conf, repositories