Differences between revisions 3 and 4
Revision 3 as of 2012-05-18 17:07:49
Size: 1647
Editor: serge-hallyn
Revision 4 as of 2012-05-18 17:09:29
Size: 1641
Editor: serge-hallyn
Deletions are marked like this. Additions are marked like this.
Line 30: Line 30:
mkdir -p /mirrors/debian/dists/precise/main-amd64/binary-amd64 mkdir -p /mirrors/debian/dists/precise/main/binary-amd64

Creating local package mirror



If you want to test a package during debootstrap, you can create a local mirror and have deboostrap refer to that.

There are probably simpler ways of doing this. Right now I'm documenting the steps I took which made this work. I suspect several steps can be dropped.


First, create the packages as you see fit.

[ much to be filled in]

I installed apt-move, not actually sure it's needed:

sudo apt-get install apt-move
sudo apt-move update

mkdir -p /mirrors/debian/pool/main
mkdir -p /mirrors/debian/dists/precise/main/binary-amd64

Copy the packages into pool/main:

cp *.deb /mirrors/debian/pool/main/

Now create Packages list:

cd /mirrors/debian
apt-ftparchive packages pool/main | gzip -9c > dists/precise/main/binary-amd64/Packages.gz

We need a Releases file:

cd /mirrors/debian
cat > releases.conf << EOF
APT::FTPArchive::Release {
Origin "APT-Move";
Label "APT-Move";
Suite "precise";
Codename "precise";
Architectures "amd64";
Components "main";
Description "Local Updates";
apt-ftparchive -c release.conf release dists/precise/ > dists/precise/Release
#gpg -bao dists/precise/Release.gpg dists/precise/Release - not needed?

Now, you can run debootstrap referring to this mirror:

debootstrap --no-check-gpg precise precise-rootfs file:///mirrors/debian

SergeHallyn_localrepo (last edited 2013-02-08 14:42:09 by serge-hallyn)