ctron / package-drone

An OSGI first software artifact repository – Moved to the Eclipse Foundation
https://github.com/eclipse/packagedrone
Eclipse Public License 1.0
39 stars 13 forks source link

Join Channel Results #96

Open gruo opened 9 years ago

gruo commented 9 years ago

Is there a way to join multiple channels to one P2 repository?

Following use case: I deploy a modular P2 application whose modules live in different Git repositories. I have an automated build process for each module and want to deploy them into different channels. After all a complete P2 repository should exists, which then can be consumed by the developers itself.

I think it is possible to deploy them into one channel but that could result in a big mess. I will dig into the second aproach.

afischer211 commented 9 years ago

You could use a simple composite repository on a web-server, in which you combine the different channels (aka P2-repositories). A composite repository is only a reference to different P2 repositories. A good feature would be the hosting of such a composite repository inside of package drone. But it is possible (and actively used by me) outside package drone on a separate web-server.

gruo commented 9 years ago

In fear of getting pretty offtopic, my setup looks as follows:

Git Repository -> Hook on Push -> Maven Build -> deploy to webserver

I encoutered some issues in the last stage of the deploy and hoped to find any management solution which does not trigger these problems (e.g. keep different versions but not build numbers). i also would like to split my big repository into module ones which result in faster builds. at the end of the day there should be a consistent development target for us.

I am also looking for any solution to partially clone the eclipse packages in a way that there should be a valid target. The ant task seems to have problems with some bundles from orbit which are not contained in any feature (JUnit).

So my intent is to have no webserver at the end of the pipe but a artifact management solution which keeps my problems rare and the artifacts in order.

ctron commented 9 years ago

The scenario you described is pretty much what we want to use Package Drone for. With our own use case being Eclipse SCADA. Several Git repository, one P2 repository. Including DEB and RPM files and a bit more.

However I also know we are not quite there yet.

The final step, combining and validating the P2 repository, is currently still a clutter of shell scripts and the two tools "b3aggr" and "p2tom2". The first combines and validates a set of P2 repositories to one big repository and claims to be able to generate a Maven repository as well. The second tool really creates a usable Maven 2 repository :wink:

You can easily create a composite P2 repository by just referencing the other repositories in an XML file. See for example the file compositeArtifacts.xml from the Eclipse SCADA update site.

So in the end Package Drone is still missing two features here (or three for us):

You can also pload a full P2 zip file and use this as repository, unpacked or using deep linking (also see Unzip Adapter). This would allow you to push each repository you built into one big channel (as you said) and let you provide a complete, composite, channel.

gruo commented 9 years ago

So it will work in some acceptable way. I do not fear XML and will check this :wink:

(I screwed the title, I see... sorry for that.)