aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authoronefang2019-12-26 17:05:35 +1000
committeronefang2019-12-26 17:05:35 +1000
commitaeb7e638ee192dddfa52c9c1723b9380f0ec6972 (patch)
treec04925bfe16f3401a27046e89747e3b098a7a7b9
parentMake the explanation linky more visible. (diff)
downloadapt-panopticon-aeb7e638ee192dddfa52c9c1723b9380f0ec6972.zip
apt-panopticon-aeb7e638ee192dddfa52c9c1723b9380f0ec6972.tar.gz
apt-panopticon-aeb7e638ee192dddfa52c9c1723b9380f0ec6972.tar.bz2
apt-panopticon-aeb7e638ee192dddfa52c9c1723b9380f0ec6972.tar.xz
Give mirrors some time to actually finish their rsynsc.
-rwxr-xr-xapt-panopticon.lua5
1 files changed, 3 insertions, 2 deletions
diff --git a/apt-panopticon.lua b/apt-panopticon.lua
index c15c369..fee4e28 100755
--- a/apt-panopticon.lua
+++ b/apt-panopticon.lua
@@ -816,9 +816,10 @@ local parseRelease = function(host)
816 pkt = tonumber(pkt:sub(2, -2)) 816 pkt = tonumber(pkt:sub(2, -2))
817 local status, new = APT.execute([[TZ="GMT" date -d "$(grep '^Date:' results/]] .. host .. [[/merged/dists/]] .. n .. [[/Release.SORTED | cut -d ' ' -f 2-)" '+%s']], false) 817 local status, new = APT.execute([[TZ="GMT" date -d "$(grep '^Date:' results/]] .. host .. [[/merged/dists/]] .. n .. [[/Release.SORTED | cut -d ' ' -f 2-)" '+%s']], false)
818 new = tonumber(new:sub(2, -2)) 818 new = tonumber(new:sub(2, -2))
819 local upd = pkt + APT.mirrors[host].Updated 819 local upd = pkt + APT.mirrors[host].Updated
820 local updd = pkt + (APT.mirrors[host].Updated * 1.5) -- Give the mirror time to actually do the update.
820 if pkt > new then 821 if pkt > new then
821 if upd >= now then 822 if updd >= now then
822 W('Release ' .. n .. ' not updated yet, should update @ ' .. os.date('!%F %T', upd), 'http', 'Updated', host) 823 W('Release ' .. n .. ' not updated yet, should update @ ' .. os.date('!%F %T', upd), 'http', 'Updated', host)
823 else 824 else
824 E('Release ' .. n .. ' not updated, should have updated @ ' .. os.date('!%F %T', upd) .. ', but was last updated @ ' .. os.date('!%F %T', new), 'http', 'Updated', host) 825 E('Release ' .. n .. ' not updated, should have updated @ ' .. os.date('!%F %T', upd) .. ', but was last updated @ ' .. os.date('!%F %T', new), 'http', 'Updated', host)