PDA

View Full Version : Custom Live CD with apt-mirror



chs2447
2018-07-31, 12:50
Hello,

I'm trying to build a full Kali mirror that includes Kali's installer files. GitHub's apt-mirror code was patched a while back to include the capability here: https://github.com/apt-mirror/apt-mirror/pull/24/commits/3e2e0f96fe3b9e64580449f080d19539cb60943b?diff=spli t#diff-04c6e90faac2675aa89e2176d2eec7d

Everything in my current apt-mirror config is working except it cannot pull the following from https://http.kali.org/kali/dists/kali-rolling/main/

installer-amd64/
installer-armel/
installer-armhf/
installer-i386/

For the above reason, building custom live cd offline fails with:

P: Begin installing debian-installer...
http://192.168.10.111:8050/kali/dists/kali-rolling/main/installer-amd64/current/images//cdrom/vmlinuz:
2018-07-30 01:41:44 ERROR 404: Not Found.
E: Could not download file: http://192.168.90.111:4038/kali/dists/kali-rolling/main/installer-amd64/current/images//cdrom/vmlinuz


My current apt-mirror mirror.list includes the following. I tried the last two lines yet it still will not pull them from Kali's repos:

######## Kali Rolling
deb https://http.kali.org/kali kali-rolling main contrib non-free
deb-src https://http.kali.org/kali kali-rolling main non-free contrib

deb-amd64 https://http.kali.org/kali kali-rolling main contrib non-free
deb-armel https://http.kali.org/kali kali-rolling main contrib non-free
deb-i386 https://http.kali.org/kali kali-rolling main contrib non-free
deb-arm64 https://http.kali.org/kali kali-rolling main contrib non-free
deb-armhf https://http.kali.org/kali kali-rolling main contrib non-free

# Kali Debian CD/Installer Files
deb https://http.kali.org/kali kali-rolling main/debian-installer main
deb-amd64 https://http.kali.org/kali kali-rolling main/debian-installer main
deb-i386 https://http.kali.org/kali kali-rolling main/debian-installer main
deb-armel https://http.kali.org/kali kali-rolling main/debian-installer main
deb-armhf https://http.kali.org/kali kali-rolling main/debian-installer main

# Tried both of the below but neither works
deb-amd64 https://http.kali.org/kali kali-rolling main netboot cdrom
deb-installer-amd64 https://http.kali.org/kali kali-rolling netboot cdrom

How can I adjust the above lines so it pulls all the directories from Kali's mirror, including the ones necessary to build CD 100% offline?

Mister_X
2018-08-01, 02:23
Not a fix for this and I'm not familiar with apt-mirror.

Give a try to apt-cacher-ng and configure the proxy on your servers. apt-cacher-ng will download the first time a package is requested then any next request will be downloaded from cache. One thing though, you probably want to block access to the web interface of apt-cacher-ng from the outside with a simple iptables rule.