-
Notifications
You must be signed in to change notification settings - Fork 0
/
repo.html
64 lines (64 loc) · 2.14 KB
/
repo.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
<!doctype html>
<html>
<head>
<title>Repository {{ .Repo.Name }} - Registry</title>
<meta charset="utf-8" />
<meta name="generator" content="https://github.com/mjl-/vex" />
<style>
body, html { padding: 1em; font-size: 16px; }
* { font-size: inherit; font-family: ubuntu, lato, sans-serif; margin: 0; padding: 0; box-sizing: border-box; }
h1, h2 { margin-bottom: 1ex; }
h1 { font-size: 1.2rem; }
h2 { font-size: 1.1rem; }
.literal { background-color: #fdfdfd; padding: .5em 1em; border: 1px solid #eee; border-radius: 4px; white-space: pre-wrap; font-family: monospace; font-size: 15px; tab-size: 4; }
.monospace { font-family: monospace; }
table > tbody > tr:nth-child(odd) { background-color: #f8f8f8; }
td, th { padding: .2em .5em; }
p { margin-bottom: 1em; max-width: 50em; }
[title] { text-decoration: underline; text-decoration-style: dotted; }
</style>
</head>
<body>
<h1>Tags for {{ .Repo.Name }} in <a href="../../">registry</a></h1>
<table>
<thead>
<tr>
<th>Tag</th>
<th>Aliases</th>
<th>Last updated</th>
<th>Size or platforms</th>
<th>Pull address</th>
</tr>
</thead>
<tbody>
{{ range .Tags -}}
<tr>
<td><a href="m/{{ .Digest }}/?tag={{ .Tag }}">{{ .Tag }}</a></td>
<td>
{{- $tag := .Tag }}
{{- range index $.ManifestTags .Digest -}}
{{ if ne .Tag $tag }}{{ .Tag }} {{ end }}
{{- end }}
</td>
<td title="{{ .Modified.UTC.Format "2006-01-02 15:04:05" }} UTC">{{ .Modified | age }}</td>
{{- $dbmanifest := index $.DBManifests .Digest }}
{{- $kind := $dbmanifest.Kind }}
{{- $parsed := index $.ParsedManifests .Digest }}
{{ if eq $kind $.ManifestKindV22 -}}
<td style="text-align: right" title="{{ $dbmanifest.ImageSize }} bytes">{{ $dbmanifest.ImageSize | formatSize }}</td>
{{ else if eq $kind $.ManifestKindListV22 -}}
<td>
{{ $parsed.Manifests | shortPlatforms }}
</td>
{{- end }}
<td>
{{ $.BaseAddress }}:{{ .Tag }}{{ if eq $kind $.ManifestKindV22 }}@{{ .Digest }}{{ end }}
</td>
</tr>
{{- else -}}
<tr><td colspan="5">None</td></tr>
{{- end }}
</tbody>
</table>
</body>
</html>