Solved Problem with poudriere and packages fetch

thierry@

Developer
Hello,
I have updated a poudriere jail to 15-CURRENT, and when I try to run `poudriere testport -b latest' it fails with this error:
Code:
[00:00:06] Package fetch: Looking for missing packages to fetch from pkg+[URL]http://pkg.freebsd.org/$[/URL]{ABI}/latest
Updating FreeBSD repository catalogue...
pkg-static: packagesite URL error for pkg+[URL]http://pkg.freebsd.org/FreeBSD:15:amd64/latest/meta.conf[/URL] -- pkg+:// implies SRV mirror type
pkg-static: packagesite URL error for pkg+[URL]http://pkg.freebsd.org/FreeBSD:15:amd64/latest/meta.txz[/URL] -- pkg+:// implies SRV mirror type
repository FreeBSD has no meta file, using default settings
pkg-static: packagesite URL error for pkg+[URL]http://pkg.freebsd.org/FreeBSD:15:amd64/latest/data.pkg[/URL] -- pkg+:// implies SRV mirror type
pkg-static: packagesite URL error for pkg+[URL]http://pkg.freebsd.org/FreeBSD:15:amd64/latest/data.tzst[/URL] -- pkg+:// implies SRV mirror type
pkg-static: packagesite URL error for pkg+[URL]http://pkg.freebsd.org/FreeBSD:15:amd64/latest/packagesite.pkg[/URL] -- pkg+:// implies SRV mirror type
pkg-static: packagesite URL error for pkg+[URL]http://pkg.freebsd.org/FreeBSD:15:amd64/latest/packagesite.tzst[/URL] -- pkg+:// implies SRV mirror type
Unable to update repository FreeBSD
Error updating repositories!
[00:00:06] Package fetch: Not fetching as remote repository is unavailable.
This is poudriere-devel-3.4.99.20250601.
Pkg works outside of poudriere, and /usr/local/poudriere/jails/15amd64/etc/pkg/FreeBSD.conf is identical with /etc/pkg/FreeBSD.conf.
It contains:
Code:
FreeBSD-ports: {
  url: "pkg+[URL]https://pkg.freebsd.org/$[/URL]{ABI}/latest",
  mirror_type: "srv",
  signature_type: "fingerprints",
  fingerprints: "/usr/share/keys/pkg",
  enabled: yes
}
Do you see anything wrong?
 
Thanks, but it seems that I encounter another problem: the error does not say that it does not find some packages, as it is often the case with poudriere -b, but that it cannot find the repository.
 
mirror_type should be set to 'SRV', which is correctly set in FreeBSD.conf, but combined with poudriere using pkg+http:// instead of pkg+https:// I'm thinking it's getting its repository information from somewhere else, and it's missing the mirror_type setting there.

Edit: Oh, check your /usr/local/etc/poudriere.conf. Specifically PACKAGE_FETCH_URL. It's probably using that instead of whatever is set in FreeBSD.conf.

Set PACKAGE_FETCH_URL=http://pkg.FreeBSD.org/\${ABI} and the 'error' should disappear.
 
Thanks, that did it!
Removing "pkg+" from the protocol in PACKAGE_FETCH_URL solved the problem.
 
Do you know of any particular reason why that cannot or shouldn't be:
None. The addition of pkg+ is the issue here, not http vs. https. pkg+ requires the mirror_type to be set to SRV, mirror_type defaults to NONE if it's not set.
 
Back
Top