simple way to creating local repository,
1. Create directory /repository at your home directory and copy all packages you have in here.
2. Execute this command inside /repository:
# dpkg-scanpackages . /dev/null | gzip -9c > Packages.gz
3. Create directory /main/dists/warty/main/binary-i386 inside repository folder.
4. Then copy file Packages to this folder
# cp Packages.gz /main/dists/warty/main/binary-i386/Packages.gz
done ..
now edit the sources.list
# vi /etc/apt/sources.list
add this line
deb file:///home/simba/repository/main/ warty main
save it and execute this command to update:
# apt-get update
then, system will show you this ..
Ign file: warty Release.gpg
Ign file: warty Release
Ign file: warty/main Packages
Reading package lists... Done
its mean that your repository is install correctly and ready to use.
but if you want to make your repository accessible from another user, you must have web server (apache) installed, then copy repository folder to publish folder (like: /var/www/repository), then edit httpd.conf and add alias.
give it a try ..
.
Ryan
No comments:
Post a Comment