我正在尝试apt-get update
使用我的 virtualmin(debian),但它因某些软件包而失败(packages.sury.org)
然后我检查包裹:
curl --verbose -SLO https://packages.sury.org/php/pool/main/p/pcre3/libpcre3_8.41-1+0~20170825202309.5+jessie~1.gbp97d153_amd64.deb
它抛出:
HTTP/1.1 403 Forbidden
< Date: Thu, 14 May 2020 00:37:49 GMT
< Content-Type: text/plain; charset=UTF-8
< Content-Length: 16
< Connection: keep-alive
< Set-Cookie: __cfduid=df716884f5fd8ee4d658ae79b60f1589416669; expires=Sat, 13-Jun-20 00:37:49 GMT; path=/; domain=.sury.org; HttpOnly; SameSite=Lax; Secure
< Cache-Control: max-age=15
< Expires: Thu, 14 May 2020 00:38:04 GMT
< Expect-CT: max-age=604800, report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct"
* Server cloudflare is not blacklisted
< Server: cloudflare
< CF-RAY: 59308d88e98bcd8f-CDG
< alt-svc: h3-27=":443"; ma=86400, h3-25=":443"; ma=86400, h3-24=":443"; ma=86400, h3-23=":443"; ma=86400
< cf-request-id: 02b236c9940000cd8fb3200000001
<
{ [data not shown]
我该如何解决?
编辑:解决方案
apt-get install apt-transport-https lsb-release ca-certificates
wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg
然后运行:apt-get update
这对我行得通!希望它对未来的人有所帮助:)