diff options
author | paxchristi888@gmail.com <paxchristi888@gmail.com> | 2019-12-08 08:10:02 +0000 |
---|---|---|
committer | paxchristi888@gmail.com <paxchristi888@gmail.com> | 2019-12-08 08:10:02 +0000 |
commit | 8506cb53ab24a19bbdbdef3cf6bb9030c9bc204f (patch) | |
tree | 4ebbcf93ad5dbe0cb95a93f688ffecc8aa0b3d54 /contrib/kiss-chroot | |
parent | 10765a73f513656d48007a09599ae5f74ed55323 (diff) | |
download | cpt-8506cb53ab24a19bbdbdef3cf6bb9030c9bc204f.tar.gz |
don't copy /etc/resolv.conf if file exists, don't rm it on clean
FossilOrigin-Name: 95401ee466066e750908e8594d431b4fac0dd21fa25991f57e734c31c6416c49
Diffstat (limited to 'contrib/kiss-chroot')
-rwxr-xr-x | contrib/kiss-chroot | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/contrib/kiss-chroot b/contrib/kiss-chroot index 372ef0a..52d5115 100755 --- a/contrib/kiss-chroot +++ b/contrib/kiss-chroot @@ -20,7 +20,6 @@ clean() { log Cleaning leftover host files; { rm -f "$1/root/.ash_history" - rm -f "$1/etc/resolv.conf" } } @@ -39,7 +38,7 @@ main() { } log Copying /etc/resolv.conf from host; { - cp /etc/resolv.conf "$1/etc" + [ ! -f "/$1/etc/resolv.conf" ] && cp /etc/resolv.conf "$1/etc" } log Entering chroot; { |