Page MenuHomeVyOS Platform

use of local cache to build iso
Closed, ResolvedPublic


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/**

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

Anyone willing to add this to the build process ?


Difficulty level
Unknown (require assessment)
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": "",
-    "debian_security_mirror": "",
+    "debian_mirror": "http://cache:3142/",
+    "debian_security_mirror": "http://cache:3142/",
-    "pbuilder_debian_mirror": "",
-    "salt_mirror": "",
+    "pbuilder_debian_mirror": "http://cache:3142/",
+    "salt_mirror": "http://cache:3142/",
-    "vyos_mirror": ""
+    "vyos_mirror": "http://cache:3142/"

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).