gnu-maintenance: Allow mirror URLs to fallback to the generic HTML updater.

* guix/gnu-maintenance.scm (http-url?): Extract from html-updatable-package?,
modify to return the HTTP URL, and support the mirror:// scheme.
(%disallowed-hosting-sites): New variable, extracted from
html-updatable-package.
(html-updatable-package?): Rewrite a mirror:// URL to an HTTP or HTTPS one.
* guix/download.scm (%mirrors): Update comment.
This commit is contained in:
Maxim Cournoyer 2023-08-11 11:21:42 -04:00
parent 6953fb9241
commit bdaef69556
No known key found for this signature in database
GPG key ID: 1260E46482E63562
2 changed files with 43 additions and 25 deletions

View file

@ -51,7 +51,10 @@
;;; Code:
(define %mirrors
;; Mirror lists used when `mirror://' URLs are passed.
;; Mirror lists used when `mirror://' URLs are passed. The first mirror
;; entry of each set should ideally be the most authoritative one, as that's
;; what the generic HTML updater will pick to look for updates, with
;; possible exceptions when the authoritative mirror is too slow.
(let* ((gnu-mirrors
'(;; This one redirects to a (supposedly) nearby and (supposedly)
;; up-to-date mirror.