Allow Satis to be used as mirror for package file downloads #34

Closed
wants to merge 2 commits into
from

Conversation

Projects
None yet
3 participants

This pull request introduces the possibility to mirror package file downloads locally with Satis. This can be helpful in a company if you use an Open Source package which hosted externally, but don't want to depend on the external hosting. For example, in the past I experienced outages of Github at the moment I wanted to deploy an application - I wasn't able to install the dependencies at this very moment. With this feature, you can use Satis to host your internal packages as well as mirror external packages in order to decouple your development and deployment from availability of external services.

The patch introduces a new config option download-files which must be set to to true if you want to enable file mirroring. It mirrors distribution types zip, tar, phar and file. In case of a Github hosted package it also mirrors dev-master.

Contributor

stof commented Aug 28, 2012

See #12 for the description of a more complete feature for it (and see the related PR in composer for the WIP)

So the full feature would also support a mirror of a SVN tag, for example?

I needed a solution right now so I came up with this which fixes my current problem and thought to share it with anyone who's interested. If you think it's not the right way to do it within Satis I'm fine with it. :-)

Contributor

stof commented Aug 28, 2012

it will.

And your feature does not work properly IMO.

  • when you call the downloader, it extracts the zip, meaning you don't have it anymore to make it available
  • the link to the dist is simply broken when the homepage is not configured

when you call the downloader, it extracts the zip, meaning you don't have it anymore to make it available

It doesn't extract the zip, it puts it exactly as it is to disk, as it always uses the file loader, even if it's a zip.

the link to the dist is simply broken when the homepage is not configured

Does it make sense to have a config without homepage? I use the output dir in such a case because I believe the repository would be given as a local filepath only.

Contributor

till commented Jan 30, 2013

Huge pitty that this doesn't get addressed. The associated PRs have been around for ages. =(

Contributor

till commented Apr 1, 2013

@mikey179 Just merged another bugfix into master. Can you try master and let us know if this matches your use-case as well? Or if there is anything missing?

mikey179 commented Apr 2, 2013

@till Thanks, I will try it, though it might take some days.

@till Just tested it, seems to fit my use case exactly. Thanks for the effort! Will close this PR now, as it's not required any more.

mikey179 closed this Apr 12, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment