diff options
author | 2020-04-28 22:20:09 -0700 | |
---|---|---|
committer | 2020-04-28 22:20:09 -0700 | |
commit | 6925ffcc3d6adef82c582c9d895878bf219a2260 (patch) | |
tree | d09965093ca3b8cb6f5ab6c18de596462de85807 | |
parent | snapshots: call new wrapper (diff) | |
download | gentoo-mirrorstats-6925ffcc3d6adef82c582c9d895878bf219a2260.tar.gz gentoo-mirrorstats-6925ffcc3d6adef82c582c9d895878bf219a2260.tar.bz2 gentoo-mirrorstats-6925ffcc3d6adef82c582c9d895878bf219a2260.zip |
switch to new refactored scripts
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
-rw-r--r-- | distfiles_mirrors/mirmon.conf | 8 | ||||
-rw-r--r-- | experimental_mirrors/mirmon.conf | 8 | ||||
-rwxr-xr-x | mirmon-distfiles.sh | 21 | ||||
-rwxr-xr-x | mirmon-experimental.sh | 21 | ||||
-rwxr-xr-x | mirmon-releases.sh | 21 | ||||
-rwxr-xr-x | mirmon-rsync.sh | 34 | ||||
-rw-r--r-- | releases_mirrors/mirmon.conf | 8 | ||||
-rw-r--r-- | rsync_mirrors/g.mirrors.extra | 6 | ||||
-rw-r--r-- | rsync_mirrors/mirmon.conf | 8 | ||||
-rw-r--r-- | snapshots_mirrors/mirmon.conf | 3 |
10 files changed, 39 insertions, 99 deletions
diff --git a/distfiles_mirrors/mirmon.conf b/distfiles_mirrors/mirmon.conf index fa2ab1b..ab0cb66 100644 --- a/distfiles_mirrors/mirmon.conf +++ b/distfiles_mirrors/mirmon.conf @@ -2,11 +2,11 @@ project_name Gentoo Linux (distfiles) web_page /var/www/mirrorstats.gentoo.org/htdocs/distfiles/index-wip.html icons ../icons countries /var/www/mirrorstats.gentoo.org/mirmon/countries.list -mirror_list /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/distfiles_mirrors/var/g.mirrors -state /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/distfiles_mirrors/var/mirmon.state +mirror_list /var/www/mirrorstats.gentoo.org/var/distfiles/g.mirrors +state /var/www/mirrorstats.gentoo.org/var/distfiles/mirmon.state probe /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/probe-mirmon %TIMEOUT% %URL%distfiles/timestamp.mirmon -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/assets/img/logo/gentoo-3d-small.png # Fresh: 0 - 8h diff --git a/experimental_mirrors/mirmon.conf b/experimental_mirrors/mirmon.conf index b27bea0..dbce73d 100644 --- a/experimental_mirrors/mirmon.conf +++ b/experimental_mirrors/mirmon.conf @@ -2,11 +2,11 @@ project_name Gentoo Linux (experimental) web_page /var/www/mirrorstats.gentoo.org/htdocs/experimental/index-wip.html icons ../icons countries /var/www/mirrorstats.gentoo.org/mirmon/countries.list -mirror_list /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/experimental_mirrors/var/g.mirrors -state /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/experimental_mirrors/var/mirmon.state +mirror_list /var/www/mirrorstats.gentoo.org/var/experimental/g.mirrors +state /var/www/mirrorstats.gentoo.org/var/experimental/mirmon.state probe /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/probe-mirmon %TIMEOUT% %URL%experimental/.timestamp-experimental.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/assets/img/logo/gentoo-3d-small.png # Fresh: 0 - 8h diff --git a/mirmon-distfiles.sh b/mirmon-distfiles.sh index 5738c99..0a245e2 100755 --- a/mirmon-distfiles.sh +++ b/mirmon-distfiles.sh @@ -1,18 +1,5 @@ #!/bin/bash - -cd /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/distfiles_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/distfiles ]] || mkdir ../../htdocs/distfiles -sed \ - -e 's#mirrors</H2>#<a href="http://www.gentoo.org/main/en/mirrors2.xml">mirrors</a></H2>#' \ - >../../htdocs/distfiles/index.html <../../htdocs/distfiles/index-wip.html -# Generate a json file containing the state of each mirror -..//generate-json.py /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/distfiles_mirrors/var/mirmon.state \ - > ../../htdocs/distfiles/state.json +exec $(dirname "$0")/mirmon-wrapper.sh \ + --mode=distfiles \ + --xml-src=distfiles \ + --url=https://www.gentoo.org/downloads/mirrors/ diff --git a/mirmon-experimental.sh b/mirmon-experimental.sh index 5b671bf..a48d57f 100755 --- a/mirmon-experimental.sh +++ b/mirmon-experimental.sh @@ -1,18 +1,5 @@ #!/bin/bash - -cd /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/experimental_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/experimental ]] || mkdir ../../htdocs/experimental -sed \ - -e 's#mirrors</H2>#<a href="http://www.gentoo.org/main/en/mirrors2.xml">mirrors</a></H2>#' \ - >../../htdocs/experimental/index.html <../../htdocs/experimental/index-wip.html -# Generate a json file containing the state of each mirror -..//generate-json.py /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/experimental_mirrors/var/mirmon.state \ - > ../../htdocs/experimental/state.json +exec $(dirname "$0")/mirmon-wrapper.sh \ + --mode=experimental \ + --xml-src=distfiles \ + --url=https://www.gentoo.org/downloads/mirrors/ diff --git a/mirmon-releases.sh b/mirmon-releases.sh index bbd5640..4839856 100755 --- a/mirmon-releases.sh +++ b/mirmon-releases.sh @@ -1,18 +1,5 @@ #!/bin/bash - -cd /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/releases_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/releases ]] || mkdir ../../htdocs/releases -sed \ - -e 's#mirrors</H2>#<a href="http://www.gentoo.org/main/en/mirrors2.xml">mirrors</a></H2>#' \ - >../../htdocs/releases/index.html <../../htdocs/releases/index-wip.html -# Generate a json file containing the state of each mirror -..//generate-json.py /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/releases_mirrors/var/mirmon.state \ - > ../../htdocs/releases/state.json +exec $(dirname "$0")/mirmon-wrapper.sh \ + --mode=releases \ + --xml-src=distfiles \ + --url=https://www.gentoo.org/downloads/mirrors/ diff --git a/mirmon-rsync.sh b/mirmon-rsync.sh index 0f37f78..d97e149 100755 --- a/mirmon-rsync.sh +++ b/mirmon-rsync.sh @@ -1,31 +1,5 @@ #!/bin/bash - -INFRA=" -albatross -boobie -dipper -quetzal -starling -swan -" - -cd /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/rsync_mirrors -# Grab mirrors from the web -[[ -d ./var ]] || mkdir ./var -../get-mirrors-from-rsync-xml.rb > ./var/g.mirrors -# infra mirrors, "manually added" to list to check -for i in ${INFRA}; do - echo "gentoo rsync://$i.gentoo.org/" >> ./var/g.mirrors -done -# 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 -[[ -d ../../htdocs/rsync ]] || mkdir ../../htdocs/rsync -# Set up a nice link to our mirror page directly: -sed \ - -e 's#mirrors</H2>#<a href="http://www.gentoo.org/main/en/mirrors-rsync.xml">mirrors</a></H2>#' \ - >../../htdocs/rsync/index.html <../../htdocs/rsync/index-wip.html -# Generate a json file containing the state of each mirror -..//generate-json.py /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/rsync_mirrors/var/mirmon.state \ - > ../../htdocs/rsync/state.json +exec $(dirname "$0")/mirmon-wrapper.sh \ + --mode=rsync \ + --xml-src=rsync \ + --url=https://www.gentoo.org/support/rsync-mirrors/ diff --git a/releases_mirrors/mirmon.conf b/releases_mirrors/mirmon.conf index 45b55e0..66201e6 100644 --- a/releases_mirrors/mirmon.conf +++ b/releases_mirrors/mirmon.conf @@ -2,11 +2,11 @@ project_name Gentoo Linux (releases) web_page /var/www/mirrorstats.gentoo.org/htdocs/releases/index-wip.html icons ../icons countries /var/www/mirrorstats.gentoo.org/mirmon/countries.list -mirror_list /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/releases_mirrors/var/g.mirrors -state /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/releases_mirrors/var/mirmon.state +mirror_list /var/www/mirrorstats.gentoo.org/var/releases/g.mirrors +state /var/www/mirrorstats.gentoo.org/var/releases/mirmon.state probe /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/probe-mirmon %TIMEOUT% %URL%releases/.timestamp-releases.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/assets/img/logo/gentoo-3d-small.png # Fresh: 0 - 8h diff --git a/rsync_mirrors/g.mirrors.extra b/rsync_mirrors/g.mirrors.extra new file mode 100644 index 0000000..340865c --- /dev/null +++ b/rsync_mirrors/g.mirrors.extra @@ -0,0 +1,6 @@ +gentoo rsync://albatross.gentoo.org +gentoo rsync://boobie.gentoo.org +gentoo rsync://dipper.gentoo.org +gentoo rsync://quetzal.gentoo.org +gentoo rsync://starling.gentoo.org +gentoo rsync://swan.gentoo.org diff --git a/rsync_mirrors/mirmon.conf b/rsync_mirrors/mirmon.conf index d285f8d..bc5904d 100644 --- a/rsync_mirrors/mirmon.conf +++ b/rsync_mirrors/mirmon.conf @@ -2,11 +2,11 @@ project_name Gentoo Linux (rsync) web_page /var/www/mirrorstats.gentoo.org/htdocs/rsync/index-wip.html icons ../icons countries /var/www/mirrorstats.gentoo.org/mirmon/countries.list -mirror_list /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/rsync_mirrors/var/g.mirrors -state /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/rsync_mirrors/var/mirmon.state +mirror_list /var/www/mirrorstats.gentoo.org/var/rsync/g.mirrors +state /var/www/mirrorstats.gentoo.org/var/rsync/mirmon.state probe /var/www/mirrorstats.gentoo.org/gentoo-mirrorstats/probe-mirmon %TIMEOUT% %URL%gentoo-portage/metadata/timestamp -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/assets/img/logo/gentoo-3d-small.png # Fresh: 0 - 1h diff --git a/snapshots_mirrors/mirmon.conf b/snapshots_mirrors/mirmon.conf index 846b994..41840c0 100644 --- a/snapshots_mirrors/mirmon.conf +++ b/snapshots_mirrors/mirmon.conf @@ -6,8 +6,7 @@ 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 ///www.gentoo.org/ -project_logo ///www.gentoo.org/images/gentoo-new.gif - +project_logo ///www.gentoo.org/assets/img/logo/gentoo-3d-small.png # Fresh: 0 - 8h # Oldish: 8 - 24h |