mirrorz-org / mirrorz-parser

0 stars 8 forks source link

Remove reverse proxy in frontend parser #5

Open ZenithalHourlyRate opened 3 years ago

ZenithalHourlyRate commented 3 years ago

Currently some sites do not have CORS for MirrorZ, so a workaround was provided by third parties using reverse proxy.

$ grep r.nichi.co * | cut -d':' -f1
cqu.js
hust.js
lzu.js
neusoft.js
nju-old.js
xjtu.js

Note: nju-old and xjtu is not deployed. The former has allowed CORS for mirrorz, see nju.js for more info; the latter one is not accessible from reverse proxy, so a static json is used instead, see /static/tmp/xjtu.json for more info.

However, for some reason this reverse proxy no longer provides service. We think this kind of workaround should only be temporary hence an issue should be set up here.

Currently parsers of cqu and neusoft uses json provided by corresponding mirror site while lzu and hust parses the html. CORS of them should be set on the mirrors. This relates to https://github.com/cqumirror/feedback/issues/27 and https://github.com/LZUOSS/Mirror/issues/13; neusoft and hust do not have an issue tracker on GitHub.

ZenithalHourlyRate commented 2 years ago

Current status:

$ grep -r zenithal
xtom-jp.js:    "https://r.zenithal.workers.dev/https://mirrors.xtom.jp/",
xtom-ee.js:    "https://r.zenithal.workers.dev/https://mirrors.xtom.ee/",
nyist.js:  const html = await (await fetch("https://r.zenithal.workers.dev/https://mirror.nyist.edu.cn/")).text();
xtom.js:    "https://r.zenithal.workers.dev/https://mirrors.xtom.com/",
xtom-nl.js:    "https://r.zenithal.workers.dev/https://mirrors.xtom.nl/",
lzu.js:  const html = await (await fetch("https://r.zenithal.workers.dev/http://mirror.lzu.edu.cn/")).text();
xtom-hk.js:    "https://r.zenithal.workers.dev/https://mirrors.xtom.com.hk/",
xtom-de.js:    "https://r.zenithal.workers.dev/https://mirrors.xtom.de/",
scau.js:  const html = await (await fetch("https://r.zenithal.workers.dev/https://mirrors.scau.edu.cn/result")).text();
ZenithalHourlyRate commented 1 year ago

Current status:

$ grep -r zenithal
xtom-nl.js:    "https://r.zenithal.workers.dev/https://mirrors.xtom.nl/",
xtom-ee.js:    "https://r.zenithal.workers.dev/https://mirrors.xtom.ee/",
xtom-de.js:    "https://r.zenithal.workers.dev/https://mirrors.xtom.de/",
xtom-jp.js:    "https://r.zenithal.workers.dev/https://mirrors.xtom.jp/",
xtom.js:    "https://r.zenithal.workers.dev/https://mirrors.xtom.com/",
xtom-hk.js:    "https://r.zenithal.workers.dev/https://mirrors.xtom.com.hk/",