Self-hosted repo

Does anyone have instructions on how to set up a FreePBX mirror/repo?

Having worked with the mirror a bit over the past few months, I don’t think it’s possible at this time. The licensing and module downloads are all mixed together right now, so that would have to be separated before we could do something like you’re talking about. I do believe the project could definitely benefit from having community hosted or even private mirrors.

1 Like

For those who are using the open-source-licensed modules only I think it would be nice if FreePBX had a switch that allowed you to just point to the Github repo or git.freepbx.org.

You might be able to offload some traffic if you went that way also.

Over simplified you need a web server that generates

http://mirror.freepbx.org/all-15.0.xml

Then you need it to return files based on location. So something like mirror.freepbx.org/modules/module/module-foo-15.0.1.tgz would return the tar ball

The actual mirror server does do a lot of crap. That said the mirror portion is as simple and complex as above.

The mirror server is not really a releasable thing. Nor as @mbrooks mentioned is it written in a way that that piece can be broken out.

Unless you’re a competitive startup with prior knowledge? :slight_smile:

The XML manifest and tgz packages are really what I’m after, so thanks for the tip, though unfortunately only the Sangoma mirrors have the .sig files (not sure why - am I missing something about how signatures work?) - so mirroring against github isn’t really going to work.

I wrote the mirror for a certain startup. I wasn’t involved in the original mirror, the rewrite, nor any of the maintenance. So I had to figure it all out. Basically went through the framework moduleadmin class and fed it what it was asking for.

Module.sig is part of the package. It isn’t hosted separately. It is generated on packaging and how to do it is documented
https://wiki.freepbx.org/display/FOP/Signing+your+own+modules

tl;dr you use the devtools package

run ./sign.php moduledir KEYID
Then you tar up the result

I think the mirror ward did simply pulled the github packages then concatenated the module.xml files. I never looked at it but I know it was static.

A good starting point:

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.