On Tue, Mar 31, 2020 at 12:58 PM Samuel Bernardo < samuelbernardo.m...@gmail.com> wrote:
> Hi Alec, > > On 3/27/20 11:20 PM, Alec Warner wrote: > > > > I should point you at man portage(5) (search for mirrors), which has > > more detail on how to set up a non-gentoo mirror network. > > Reading portage manpage about mirrors I didn't find the mirror type > possible values. As I could understand, there is type local as a special > mirror and then, from the example, sourceforge and gnu. Didn't > understand right how this works. > > From thirdpartymirrors file I can see more examples... The mirror type > can be any label that I decide to use? > man portage(5) says: Whenever portage encounters a mirror:// style URI it will look up the actual hosts here. If the mirror set is not found here, it will check the global mirrors file at /var/db/repos/gentoo/profiles/thirdpartymirrors. You may also set a special mirror type called "local". This list of mirrors will be checked before GENTOO_MIRRORS and will be used even if the package has RESTRICT="mirror" or RESTRICT="fetch". We have a bunch of existing mirror types (as you noticed). This lets us do things like "mirror://github" and then globally change the uri for github easily without editing the entire set of ebuilds because we late-bind the URI matching. > > Is URI mirror:// style deprecated in ebuilds and should use > restric="mirror" instead? > I don't understand how you could arrive at this conclusion. What would this do? RESTRICT=mirror is for things we are not legally allowed to mirror. That's basically all its for; it has nothing to do with custom mirrors or anything. > > I think that, in mirrors description for /etc/portage/, first paragraph > should be divided in two: the new one in the phrase that starts with > "You may also set a special mirror type called local". > Feel free to submit a patch; the source is on github: https://github.com/gentoo/portage/blob/master/man/portage.5 -A > > Thanks, > > Samuel > > >