第一次提交测试 2025.07.20 skimrme

This commit is contained in:
skimrme
2025-07-20 01:52:15 +08:00
parent d533642938
commit 7b6373f474
19 changed files with 444 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
<?php
// 1. 定义你的 Docker Registry 地址
// 请将 'http://localhost:5000' 替换为你的实际 Registry 地址。
// 例如:如果你的 Registry 是 'my-registry.io',就改为 'https://my-registry.io'
$registryUrl = "https://regw.ww3.tw/";
// 2. 定义你要获取的 API 端点
// 这个端点用于获取所有仓库列表。
$endpoint = "/v2/_catalog";
// 3. 组合完整的 URL
$fullUrl = $registryUrl . $endpoint;
// 4. 使用 file_get_contents() 获取 JSON 内容
// @ 符号用来抑制可能出现的错误或警告,让输出更干净。
$jsonContent = @file_get_contents($fullUrl);
// 5. 直接输出 JSON 内容
// 如果成功获取到内容,就直接打印出来。
// 如果获取失败会打印一个空字符串或PHP的错误信息如果没用@抑制)。
header('Content-Type: application/json'); // 告诉浏览器这是一个JSON响应
echo $jsonContent;
?>

View File

@@ -0,0 +1,11 @@
<html>
<head>
<title>docker-registry</title>
<meta charset="utf-8" lang="zh-CN">
</head>
<body>
<a href="./all-images/index.php">查看所有镜像</a>
<p>tags/list</p>
</body>
</html>