* [gentoo-commits] proj/gentoo-mirrorstats:master commit in: snapshots_mirrors/, /
@ 2020-04-28 17:29 Robin H. Johnson
0 siblings, 0 replies; 2+ messages in thread
From: Robin H. Johnson @ 2020-04-28 17:29 UTC (permalink / raw
To: gentoo-commits
commit: c830c7267db4b8ed88e440a39e75768a20fd9fa0
Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
AuthorDate: Tue Apr 28 17:29:31 2020 +0000
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
CommitDate: Tue Apr 28 17:29:31 2020 +0000
URL: https://gitweb.gentoo.org/proj/gentoo-mirrorstats.git/commit/?id=c830c726
snapshots: also test this
Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org>
mirmon-snapshots.sh | 18 ++++++++++++++++++
snapshots_mirrors/mirmon.conf | 23 +++++++++++++++++++++++
2 files changed, 41 insertions(+)
diff --git a/mirmon-snapshots.sh b/mirmon-snapshots.sh
new file mode 100644
index 0000000..692a1ef
--- /dev/null
+++ b/mirmon-snapshots.sh
@@ -0,0 +1,18 @@
+#!/bin/bash
+
+cd /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/snapshots_mirrors
+# Grab mirrors from the web
+[[ -d ./var ]] || mkdir ./var
+../get-mirrors-from-distfiles-xml.rb > ./var/g.mirrors
+# fatal if the state file is NOT present.
+[[ -e ./var/mirmon.state ]] || touch ./var/mirmon.state
+# run mirmon
+/usr/bin/perl ../../mirmon/mirmon -c ./mirmon.conf -q -get update
+# Set up a nice link to our mirror page directly:
+[[ -d ../../htdocs/snapshots ]] || mkdir ../../htdocs/snapshots
+sed \
+ -e 's#mirrors</H2>#<a href="http://www.gentoo.org/main/en/mirrors2.xml">mirrors</a></H2>#' \
+ >../../htdocs/snapshots/index.html <../../htdocs/snapshots/index-wip.html
+# Generate a json file containing the state of each mirror
+../json/generate-json.py /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/snapshots_mirrors/var/mirmon.state \
+ > ../../htdocs/snapshots/state.json
diff --git a/snapshots_mirrors/mirmon.conf b/snapshots_mirrors/mirmon.conf
new file mode 100644
index 0000000..6d689bb
--- /dev/null
+++ b/snapshots_mirrors/mirmon.conf
@@ -0,0 +1,23 @@
+project_name Gentoo Linux (snapshots)
+web_page /var/www/mirrorstats.gentoo.org/htdocs/snapshots/index-wip.html
+icons ../icons
+countries /var/www/mirrorstats.gentoo.org/mirmon/countries.list
+mirror_list /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/snapshots_mirrors/var/g.mirrors
+state /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/snapshots_mirrors/var/mirmon.state
+probe /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/probe-mirmon %TIMEOUT% %URL%snapshots/.timestamp-snapshots.x
+project_url http://www.gentoo.org/
+project_logo http://www.gentoo.org/images/gentoo-new.gif
+
+
+# Fresh: 0 - 8h
+# Oldish: 8 - 24h
+# Old: 24h - inf
+# Bad: No reachable, no state saved
+
+max_poll 4h
+min_sync 4h
+max_sync 20h
+
+put_histo top
+timeout 30
+
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [gentoo-commits] proj/gentoo-mirrorstats:master commit in: snapshots_mirrors/, /
@ 2020-04-29 4:05 Robin H. Johnson
0 siblings, 0 replies; 2+ messages in thread
From: Robin H. Johnson @ 2020-04-29 4:05 UTC (permalink / raw
To: gentoo-commits
commit: 14510bcfe2f4639f971d6c478124648eb1e26a6b
Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
AuthorDate: Wed Apr 29 04:05:33 2020 +0000
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
CommitDate: Wed Apr 29 04:05:33 2020 +0000
URL: https://gitweb.gentoo.org/proj/gentoo-mirrorstats.git/commit/?id=14510bcf
snapshots: fix var dir switch
Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org>
mirmon-snapshots.sh | 2 +-
snapshots_mirrors/mirmon.conf | 8 ++++----
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/mirmon-snapshots.sh b/mirmon-snapshots.sh
index 894e94b..ee0338b 100755
--- a/mirmon-snapshots.sh
+++ b/mirmon-snapshots.sh
@@ -6,7 +6,7 @@ MODE=snapshots
SRC=distfiles
SITEDIR=/var/www/mirrorstats.gentoo.org
REPODIR=${SITEDIR}/gentoo-mirrorstats/
-MODEDIR=${SITEDIR}/${MODE}_mirrors/
+MODEDIR=${REPODIR}/${MODE}_mirrors/
VARDIR=${SITEDIR}/var/${MODE}
HTDOCS=${SITEDIR}/htdocs/${MODE}
MIRMON=$(readlink -f "${SITEDIR}"/mirmon/mirmon)
diff --git a/snapshots_mirrors/mirmon.conf b/snapshots_mirrors/mirmon.conf
index 6d689bb..846b994 100644
--- a/snapshots_mirrors/mirmon.conf
+++ b/snapshots_mirrors/mirmon.conf
@@ -2,11 +2,11 @@ project_name Gentoo Linux (snapshots)
web_page /var/www/mirrorstats.gentoo.org/htdocs/snapshots/index-wip.html
icons ../icons
countries /var/www/mirrorstats.gentoo.org/mirmon/countries.list
-mirror_list /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/snapshots_mirrors/var/g.mirrors
-state /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/snapshots_mirrors/var/mirmon.state
+mirror_list /var/www/mirrorstats.gentoo.org/var/snapshots/g.mirrors
+state /var/www/mirrorstats.gentoo.org/var/snapshots/mirmon.state
probe /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/probe-mirmon %TIMEOUT% %URL%snapshots/.timestamp-snapshots.x
-project_url http://www.gentoo.org/
-project_logo http://www.gentoo.org/images/gentoo-new.gif
+project_url ///www.gentoo.org/
+project_logo ///www.gentoo.org/images/gentoo-new.gif
# Fresh: 0 - 8h
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-04-29 4:05 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-04-28 17:29 [gentoo-commits] proj/gentoo-mirrorstats:master commit in: snapshots_mirrors/, / Robin H. Johnson
-- strict thread matches above, loose matches on Subject: below --
2020-04-29 4:05 Robin H. Johnson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox