Skip to content

Instantly share code, notes, and snippets.

@avleen
Last active October 6, 2016 23:12
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save avleen/63e670295fd6942a401bdcf6bdd345c4 to your computer and use it in GitHub Desktop.
Save avleen/63e670295fd6942a401bdcf6bdd345c4 to your computer and use it in GitHub Desktop.
Multi-protocol caching package management proxy
A multi-threaded process which listens on port 80 for connections from yum, apt, npm, gem, etc.
It recognises the kind of request made (yum, apt, npm, gem) automatically and responds accordingly.
If a requested package is available locally, it is served.
If not, it is fetched from a configured list of upstream servers, cached and served.
On a regular basis, the process retreives a package list (eg, Repodata.xml) from its upstream servers,
and merges it with a list of local packages.
Users provide mappings for where to point for each repo (eg: cent 7, cent 7 updates, npm, etc). Eg:
request_uri: /centos-7
- upstream: http://...
- local_dir: s3://pkgcacher.example.com/centos-7
- daily_sync_time: 05:30
request_uri: /gems
- upstream: http://...
- local_dir: /var/cache/pkgcacher/gems
- daily_sync_time: 05:45
s3_credentials:
- access_key_id: ...
- secret_access_key: ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment