cphosts() will be moved to dchr-bs
This commit is contained in:
parent
bc6e29c3fb
commit
1dcddba5f9
1 changed files with 0 additions and 14 deletions
14
run.sh
14
run.sh
|
@ -26,19 +26,6 @@ setup () {
|
||||||
mount -o bind /run "$1/run"
|
mount -o bind /run "$1/run"
|
||||||
}
|
}
|
||||||
|
|
||||||
cphosts () {
|
|
||||||
if ! [ -e "$1/etc/hosts" ]
|
|
||||||
then
|
|
||||||
echo '-- Copying hosts'
|
|
||||||
cp /etc/hosts "$1/etc/hosts"
|
|
||||||
fi
|
|
||||||
if ! [ -e "$1/etc/resolv.conf" ]
|
|
||||||
then
|
|
||||||
echo '-- Copying resolv.conf'
|
|
||||||
cp /etc/resolv.conf "$1/etc/resolv.conf"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
runcmd () {
|
runcmd () {
|
||||||
echo -e '-- \e[1;32mOK\e[0m -- running chroot'
|
echo -e '-- \e[1;32mOK\e[0m -- running chroot'
|
||||||
chroot "$1" "$2"
|
chroot "$1" "$2"
|
||||||
|
@ -58,7 +45,6 @@ main () {
|
||||||
trap "clean $chrdir" EXIT
|
trap "clean $chrdir" EXIT
|
||||||
|
|
||||||
setup "$chrdir"
|
setup "$chrdir"
|
||||||
cphosts "$chrdir"
|
|
||||||
runcmd "$chrdir" "$chrcmd"
|
runcmd "$chrdir" "$chrcmd"
|
||||||
exit $?
|
exit $?
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue