Page MenuHomeVyOS Platform

use of local cache to build iso
Closed, ResolvedPublic

Description

I have a machine running apt-cacher-ng which caches all .deb packages to be served locally.
I would like to be able, when building an iso, to get all deb's from my local source.

In normal debian machines you either set:

/etc/apt/apt.conf with the contents
**Acquire::http::Proxy "http://cache:3142/";**
of course in my case local dns is able to resolve the host "cache"

Or you could put the diversion in /etc/apt/sources.list like this
**deb http://cache:3142/deb.debian.org/debian/**

This would save both traffic and speed when compiling vyos iso images.

Anyone willing to add this to the build process ?

Details

Difficulty level
Unknown (require assessment)
Version
-
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Unspecified (possibly destroys the router)
Issue type
Feature (new functionality)

Event Timeline

@fromport there is an option in the ./configure script tomspecify the Debian mirror you use. You should be able to simply point it to your mirror.

configure -h is a bit "cryptic" (imo)
It doesn't show the defaults, so i ran a regular configure and then editted the build/build-config.json

diff -u

-    "debian_mirror": "http://deb.debian.org/debian",
-    "debian_security_mirror": "http://deb.debian.org/debian-security",
+    "debian_mirror": "http://cache:3142/deb.debian.org/debian",
+    "debian_security_mirror": "http://cache:3142/deb.debian.org/debian-security",
-    "pbuilder_debian_mirror": "http://deb.debian.org/debian",
-    "salt_mirror": "http://repo.saltstack.com/apt/debian/8/amd64/2017.7",
+    "pbuilder_debian_mirror": "http://cache:3142/deb.debian.org/debian",
+    "salt_mirror": "http://cache:3142/repo.saltstack.com/apt/debian/8/amd64/2017.7",
-    "vyos_mirror": "http://dev.packages.vyos.net/repositories/current"
+    "vyos_mirror": "http://cache:3142/dev.packages.vyos.net/repositories/current"

That did the trick and I think shaved more than 5 minutes of my build time

syncer added a project: Restricted Project.Mar 16 2019, 7:03 PM
syncer added subscribers: rob, syncer.

@rob probably good to add to KB this one

erkin set Is it a breaking change? to Unspecified (possibly destroys the router).Aug 31 2021, 6:59 PM
erkin set Issue type to Feature (new functionality).