Please add *.wmflabs.org to wgCopyUploadsDomains on Wikimedia Commons. This would allow bots to make the WMF server pull files instead of having the complicated and error-prone upload part on my side.
Description
Details
| Status | Subtype | Assigned | Task | |
|---|---|---|---|---|
| · · · | ||||
| Resolved | None | T60224 Add domains to $wgCopyUploadsDomains (tracking) | ||
| Declined | None | T78167 Add *.toolforge.org to `wgCopyUploadsDomains` | ||
| Resolved | akosiaris | T95714 Allow the production cluster to access *.wmflabs.org IPs | ||
| · · · |
Event Timeline
Change 179094 had a related patch set uploaded (by Steinsplitter):
Adding *.wmflabs.org to wgCopyUploadsDomains
Another advantage is that production servers would decide when they want to fetch the file.
Last I checked, production servers can't talk to labs, so even if you add the domain, I'm pretty sure it won't work.
legoktm@terbium:~$ HTTPS_PROXY=url-downloader.wikimedia.org:8080 curl https://tools.wmflabs.org/legobot/hi.txt curl: (56) Received HTTP code 403 from proxy after CONNECT
production servers can't talk to labs
And what is the reason for that? The same invalid one as in T44473 ?
Change 179094 abandoned by Steinsplitter:
Adding *.wmflabs.org to wgCopyUploadsDomains
Reason:
see T78167, wmflabs in internal, so it dosen't work
Hi, Could you speed up this task a bit please? It would be quite useful for many tools on the Labs (e.g. https://tools.wmflabs.org/yifeibot/gallica.py). It is not really a great deal to reconfigure a proxy...
The use case from T78167 is for wgCopyUploadsDomain:
legoktm@terbium:~$ HTTPS_PROXY=url-downloader.wikimedia.org:8080 curl https://tools.wmflabs.org/legobot/hi.txt curl: (56) Received HTTP code 403 from proxy after CONNECT
If I try again now, it seems to pass with:
HTTPS_PROXY=url-downloader.wikimedia.org:8080 curl https://tools.wmflabs.org/
Maybe the url-downloader did not have access to the labs reverse proxy / tools-wmflabs.org ..
So we're declining the task, with the precision it could be allowed in the future to allow <subdomain>.wmflabs.org.
T95714: Allow the production cluster to access *.wmflabs.org IPs was Resolved. Can we update this task ?
For example, can someone test on prod cluster this command ?
If it's good, we probably will be able to merge the patch that simply add the domain to the whitelist.
Yes that works, per my comment two years ago T95714#1470497 and I have confirmed it again right now:
terbium$ HTTPS_PROXY=url-downloader.wikimedia.org:8080 curl https://tools.wmflabs.org/robots.txt User-agent: * Crawl-delay: 3 ...
Most probably, url-downloader.wikimedia.org was not able to reach the wmflabs proxy.
So I guess it now it depends whether we want to allow $wgCopyUploadsDomains = '*.wmflabs.org' or a subset of subdomains or whatever. I can not tell.
Based on T292213 (and also T255363), I tried to upload a file from https://wikisource-bot.toolforge.org and it looks good, and I believe there should be no technical barrier from implementing this. Also as stated in T95714#1303192, we should trust those (toolforge user).
Change 791059 had a related patch set uploaded (by Stang; author: Stang):
[operations/mediawiki-config@master] commonswiki: Add *.toolforge.org to wgCopyUploadsDomains allowlist
Change 791059 abandoned by Stang:
[operations/mediawiki-config@master] commonswiki: Add *.toolforge.org to wgCopyUploadsDomains allowlist
Reason:
Per Majavah's comment
Per Majavah's comment, It would be much better, from the security perspective, to maintain a whitelist for some tools only. Close as decline.