Re: Pkg repository is broken...

From: Matthew Seaman <matthew_at_FreeBSD.org>
Date: Sun, 8 Mar 2020 10:31:53 +0000
On 07/03/2020 22:38, Greg 'groggy' Lehey wrote:
>> This was only an issue on the "latest" branch. If you don't alter
>> "/etc/pkg/FreeBSD.conf", you'll get packages from the "quarterly"
>> branch, which fortunately wasn't affected.

> No, this isn't necessarily correct.  I have never modified this file,
> but I ended up with a copy of /usr/src/usr.bin/pkg/FreeBSD.conf.latest
> with this revision string:
> 
>   # $FreeBSD: stable/11/etc/pkg/FreeBSD.conf 263937 2014-03-30 15:24:17Z bdrewery $
> 
> Despite the age, this appears to identical to the current version,
> according to svn blame.  Arguably this should be the default anyway.
> 

Best practice is *not* to modify /etc/pkg/FreeBSD.conf, but to create a
supplemental file /usr/local/etc/pkg/repos/FreeBSD.conf to override any
of the default settings.

So, for example, this in /usr/local/etc/pkg/repos/FreeBSD.conf will
switch to the 'latest' package set:

```
FreeBSD: { url: "pkg+http://pkg.FreeBSD.org/${ABI}/latest" }
```

and this will disable the FreeBSD pkg repos entirely:

```
FreeBSD: { enabled: no }
```

(presumably with an additional .../pkg/repos/foo.conf file to enable a
custom local repository)

The best way to confirm exactly what the resultant pkg(8) configuration
comes out as is by:

   pkg -vv

	Cheers,

	Matthew


Received on Sun Mar 08 2020 - 09:31:58 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:41:23 UTC