Docker: update header for file retrieval

Solves the "unavailable" message which sometimes appears after checking for updates
This commit is contained in:
bergware
2023-01-24 19:50:41 +01:00
parent f1f59c899e
commit 77b86bf8b0
@@ -445,7 +445,7 @@ class DockerUpdate{
/*
* Step 2: Get www-authenticate header from manifest url to generate token or basic auth
*/
$header = ['Accept: application/vnd.docker.distribution.manifest.list.v2+json,application/vnd.docker.distribution.manifest.v2+json'];
$header = ['Accept: application/vnd.docker.distribution.manifest.list.v2+json,application/vnd.docker.distribution.manifest.v2+json,application/vnd.oci.image.index.v1+json'];
$digest_ch = getCurlHandle($manifestURL, 'HEAD', $header);
preg_match('@www-authenticate:\s*Bearer\s*(.*)@i', $reply, $matches);
if (!empty($matches[1])) {