Browse Source

Add a linky to the graphs for each mirror.

Also includes the place holder for the stil being debugged weekly
averages.
master
onefang 3 years ago
parent
commit
3442d0d038
  1. 19
      apt-panopticon-report-email-web.lua
  2. 6
      explanations.html

19
apt-panopticon-report-email-web.lua

@ -362,7 +362,8 @@ if nil == web then C("opening mirrors file - " .. e) else
"<p><font color='grey'><b>skip</b></font> means that the test hasn't been written yet.</p>\n" ..
"<table>\n<tr><th></th><th>" .. lnk('FTP') .. "</th><th>" .. lnk('HTTP') .. "</th><th>" .. lnk('HTTPS') .. "</th><th>" .. lnk('RSYNC') .. "</th>" ..
"<th>" .. lnk('DNS round robin', 'DNS-RR') .. "</th><th>" .. lnk('Protocol') .. "</th><th>" .. lnk('URL sanity', 'URL-Sanity') .. "</th><th>" .. lnk('Integrity') .. "</th>" ..
"<th>" .. lnk('Updated') .. "</th><th colspan='2'>" .. lnk('Speed range', 'Speed') .. "</th></tr>\n"
"<th>" .. lnk('Updated') .. "</th><th colspan='2'>" .. lnk('Speed range', 'Speed') .. "</th>" ..
"<th colspan='2'>" .. lnk('Weekly averages', 'Weekly') .. "</th><th>" .. lnk('Graphs') .. "</th></tr>\n"
)
local bg = ''
@ -390,6 +391,8 @@ if nil == web then C("opening mirrors file - " .. e) else
local min = tonumber(results.speed.min)
local max = tonumber(results.speed.max)
local spd = '<td></td><td></td>'
local week = '<td>xxx% up</td><td>xxx% updated</td>'
local graph = '<a href="../apt-panopticon_cgp/host.php?h=' .. k .. '">graphs</a>'
-- DNS-RR test.
if ("deb.devuan.org" ~= k) and (nil ~= APT.mirrors["deb.devuan.org"]) then
@ -430,8 +433,8 @@ if nil == web then C("opening mirrors file - " .. e) else
end
web:write("<td>" .. ftp .. "&nbsp;</td><td>" .. http .. "&nbsp;</td><td>" .. https .. "&nbsp;</td><td>" .. rsync .. "&nbsp;</td><td>" .. dns ..
"&nbsp;</td><td>" .. protocol .. "&nbsp;</td><td>" .. sanity ..
"&nbsp;</td><td>" .. integrity .. "&nbsp;</td><td>" .. updated .. "&nbsp;</td>" .. spd .. "</tr>\n")
"&nbsp;</td><td>" .. protocol .. "&nbsp;</td><td>" .. sanity .. "&nbsp;</td><td>" .. integrity .. "&nbsp;</td><td>" .. updated ..
"&nbsp;" .. spd .. "&nbsp;" .. week .."&nbsp;<td>" .. graph .. "</td></tr>\n")
if "" ~= active then
web:write("<tr><td style='background-color:dimgrey'>" .. active .. "</td></tr>\n")
end
@ -487,7 +490,9 @@ if nil == web then C("opening mirrors file - " .. e) else
"<table>\n<tr><th></th><th>" .. lnk('FTP') .. "</a></th><th>" .. lnk('HTTP') .. "</th><th>" .. lnk('HTTPS') .. "</th><th>" .. lnk('RSYNC') .. "</th>" ..
"<th>" .. lnk('DNS round robin', 'DNS-RR') .. "</th><th>" .. lnk('Protocol') .. "</th><th>" .. lnk('URL sanity', 'URL-Sanity') .. "</th><th>" .. lnk('Integrity') .. "</th>" ..
"<th>" .. lnk('Updated') .. "</th><th colspan='2'>" .. lnk('Speed range', 'Speed') .. "</th></tr>\n")
"<th>" .. lnk('Updated') .. "</th><th colspan='2'>" .. lnk('Speed range', 'Speed') .. "</th>" ..
"<th colspan='2'>" .. lnk('Weekly averages', 'Weekly') .. "</th><th>" .. lnk('Graphs') .. "</th></tr>\n"
)
for k, v in APT.orderedPairs(APT.debians) do
if '' == bg then bg = " style='background-color:#111111'" else bg = '' end
local results = APT.collateAll(APT.debians, 'results', k)
@ -512,6 +517,8 @@ if nil == web then C("opening mirrors file - " .. e) else
local min = tonumber(results.speed.min)
local max = tonumber(results.speed.max)
local spd = '<td></td><td></td>'
local week = '<td>xxx% up</td><td>xxx% updated</td>'
local graph = '<a href="../apt-panopticon_cgp/host.php?h=' .. k .. '">graphs</a>'
-- DNS-RR test.
if ("deb.devuan.org" ~= k) and (nil ~= APT.debians["deb.devuan.org"]) then
@ -552,8 +559,8 @@ if nil == web then C("opening mirrors file - " .. e) else
end
web:write("<td>" .. ftp .. "&nbsp;</td><td>" .. http .. "&nbsp;</td><td>" .. https .. "&nbsp;</td><td>" .. rsync .. "&nbsp;</td><td>" .. dns ..
"&nbsp;</td><td>" .. protocol .. "&nbsp;</td><td>" .. sanity ..
"&nbsp;</td><td>" .. integrity .. "&nbsp;</td><td>" .. updated .. "&nbsp;</td>" .. spd .. "</tr>\n")
"&nbsp;</td><td>" .. protocol .. "&nbsp;</td><td>" .. sanity .. "&nbsp;</td><td>" .. integrity .. "&nbsp;</td><td>" .. updated ..
"&nbsp;</td>" .. spd .. "&nbsp;" .. week .."&nbsp;<td>" .. graph .. "</td></tr>\n")
if "" ~= active then
web:write("<tr><td style='background-color:dimgrey'>" .. active .. "</td></tr>\n")
end

6
explanations.html

@ -77,4 +77,10 @@ Finally, the tested mirror may have a bigger network connection than the compute
So take this speed measurement with a grain of salt, it's more of an indication, the <a href="../apt-panopticon_cgp/index.php">full graphs</a> might be useful.
</p>
<hr><h1 id="Weekly">Weekly averages</h1>
<p>This is the percentage of time the mirror was up, and the mirror was up to date.</p>
<hr><h1 id="Graphs">Graphs</h1>
<p>A link to the graphs for this mirror.</p>
</body></html>

Loading…
Cancel
Save