chroot $rootfs /usr/sbin/update-rc.d -f hwclockfirst.sh remove
}
+arch=$(arch)
+
download_debian()
{
packages=\
openssh-server
cache=$1
- arch=$2
# check the mini debian was not already downloaded
mkdir -p "$cache/partial-$arch"
copy_debian()
{
cache=$1
- arch=$2
rootfs=$3
# make a local copy of the minidebian
return 1
fi
- arch=$(arch)
if [ "$arch" == "x86_64" ]; then
arch=amd64
fi
usage()
{
cat <<EOF
-$1 -h|--help -p|--path=<path> --clean
+$1 -h|--help -p|--path=<path> -a|--arch=stable --clean
EOF
return 0
}
-options=$(getopt -o hp:n:c -l help,path:,name:,clean -- "$@")
+options=$(getopt -o hp:n:ca: -l help,path:,name:,clean,arch: -- "$@")
if [ $? -ne 0 ]; then
usage $(basename $0)
exit 1
case "$1" in
-h|--help) usage $0 && exit 0;;
-p|--path) path=$2; shift 2;;
- -n|--name) name=$2; shift 2;;
- -c|--clean) clean=$2; shift 2;;
+ -n|--name) name=$2; shift 2;;
+ -c|--clean) clean=$2; shift 2;;
+ -a|--arch) arch=$2; shift 2;;
--) shift 1; break ;;
*) break ;;
esac