#!/bin/sh # generate a partial Debian mirror with debootstrap and apt-move # 2004-02, W. Borgert # Released under the terms of the GNU General Public License # 2012-12 Modified by Jorge Suárez de Lis # 2014-07 Modified again by Jorge Suárez de Lis # the root directory of the mirror system CHROOT64=/var/local/chroot-amd64 CHROOT32=/var/local/chroot-i386 # the mirror directory inside of the chroot MIRRORDIR64=/var/local/mirrors-amd64 MIRRORDIR32=/var/local/mirrors-i386 # the Debian archive next to you DEBIANREPO=http://fr.archive.ubuntu.com/ubuntu # the release name RELEASENAME=trusty #### OUT=adduser,aptitude,apt-utils,at,base-config,bsdmainutils,\ console-common,console-data,console-tools,cpio,cron,debconf-i18n,\ dhcp-client,ed,exim4,exim4-base,exim4-config,exim4-daemon-light,\ fdutils,gettext-base,groff-base,ifupdown,info,ipchains,iptables,\ iputils-ping,klogd,libconsole,libgcrypt1,libgcrypt7,libgdbm3,\ libgnutls10,libgpg-error0,libident,liblocale-gettext-perl,\ liblockfile1,liblzo1,libnewt0.51,libopencdk8,libpcap0.7,libpcre3,\ libpopt0,libsigc++-1.2-5c102,libssl0.9.7,libtasn1-0,\ libtext-charwidth-perl,libtext-iconv-perl,libtext-wrapi18n-perl,\ libwrap0,lilo,logrotate,mailx,makedev,man-db,manpages,mbr,modconf,\ modutils,nano,netbase,netkit-inetd,net-tools,nvi,pciutils,ppp,\ pppconfig,pppoe,pppoeconf,procps,psmisc,setserial,slang1,sysklogd,\ syslinux,sysvinit,tasksel,tcpd,telnet,wget,whiptail IN=apt-move,bc,bzip2,dash,debconf,libbz2-1.0,libpam0g,\ libreadline5 #### apt-get install debootstrap mkdir -p $CHROOT64$MIRRORDIR64/ubuntu debootstrap --components=main,universe --exclude="$OUT" --include="$IN" $RELEASENAME $CHROOT64 $DEBIANREPO mkdir -p $MIRRORDIR64 ln -s $CHROOT64$MIRRORDIR64/ubuntu $MIRRORDIR64 mkdir -p $CHROOT32$MIRRORDIR32/ubuntu debootstrap --components=main,universe --exclude="$OUT" --include="$IN" $RELEASENAME $CHROOT32 $DEBIANREPO mkdir -p $MIRRORDIR32 ln -s $CHROOT32$MIRRORDIR32/ubuntu $MIRRORDIR32