Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/bmwiedemann/opensuse-redir-cache
simple local caching proxy
https://github.com/bmwiedemann/opensuse-redir-cache
Last synced: about 1 month ago
JSON representation
simple local caching proxy
- Host: GitHub
- URL: https://github.com/bmwiedemann/opensuse-redir-cache
- Owner: bmwiedemann
- Created: 2023-01-23T11:13:30.000Z (almost 2 years ago)
- Default Branch: master
- Last Pushed: 2023-05-29T16:46:19.000Z (over 1 year ago)
- Last Synced: 2024-11-20T09:26:14.995Z (about 2 months ago)
- Language: Perl
- Size: 2.93 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Why
Speed up openSUSE downloads,
similar to https://github.com/Firstyear/opensuse-proxy-cache# Assumtions
* traffic is plenty and cheap - e.g. you run this in your LAN
# How
* keep alive HTTP connections to relevant servers to allow to fetch small files in 1 RTT
* avoid added latency from external MirrorCache redirectors - instead we do a quick on-the-fly mirror scan ourselves
* avoid added latency from round-trips to Nuremberg main server - we only ever talk to closeby mirrors - except at start to find these mirrors
* cache files smaller than N KiB ; e.g. 70% of Tumbleweed rpms are below 200 KiB and together only take up 2 GiB of storage. This helps, if you have multiple openSUSE machinesRequests go zypper -> cache -> redirector -> mirrors|download.o.o
This redirector needs to
* fetch a list of closeby mirrors once from regional mirrorcache
* do parallel GET+HEAD requests to different mirrors
* optional: parse primary.xml to know which files are small and get these from CDN directly (if faster than mirrors)
* optional: track file-availability and performance of mirrors to send more GET requests to the best one and fewer HEAD requests overall if everything works fine# Usage
http_proxy=http://localhost:8000/ zypper up