APT repository mirrors
How to configure a repository mirror for APT
Now we have a working installation it's time to set up mirrors for package repositories.
Although you can call the repositories anything you want, it's advisable to keep to a naming convention. The number of repositories will grow over time, and it will become obvious later which repository is for which package manager.
Because of this I advise the following:
-
as a word separator. Never use a space.
apt
for an apt repository,
npm
for a node/npm repository etc.
apt-debian
for Debian,
apt-ubuntu
for Ubuntu
or apt-raspbian
for Raspberry PI OS.
apt-debian-security
for the Debian security repository.
Keeping to this scheme will make it easier to maintain as well as keeping like repositories next to each other within the Nexus UI.
Each repository mirror requires an object store to store the cached artefacts. It's advisable to create a new object store for each type of repository.
So for any mirror whose name starts with apt-debian
then create a keystore called
debian
and use it as the backing store for all of them.
Do the same for Ubuntu, Raspberry PI OS etc.
If you are mirroring third party repositories like NVidia or OBS then you can either create an object store
for each or create one called thirdparty
and use that for those smaller repositories.
The naming is up to you, but it can help in keeping artefacts separate & not have individual large stores.
The following subsections list how to configure each repository type:
How to configure a repository mirror for APT
How to configure a mirror for NPM
How to configure a mirror for PIP