Best Practice: artifacts w/ multiple arch/os and yum repo

276 views
Skip to first unread message

Leonard Basuino

unread,
Jul 11, 2016, 6:38:51 AM7/11/16
to nexus...@glists.sonatype.com
I'm looking for the "Best Practice" model for creating and publishing rpm artifacts for the same GA and V(?) but for different architectures and OS versions.
For example. If I have an rpm, foo.rpm that has different content for 32 and 64 bit architecture as well as different for RHEL 6 and RHEL 7, how would this best be created and stored in Nexus so the Nexus yum repo(s) would be created correctly.
TIA!
Lenny B.

Rich Seddon

unread,
Jul 11, 2016, 9:54:56 AM7/11/16
to Leonard Basuino, nexus...@glists.sonatype.com

It sounds like you're referring to aggregated yum repositories in the style that RedHat typically uses, where the yum repositories for a particular version/os/architecture are in a hierarchy:

http://somerepo.centos.org/5.10/os/x86_64/
http://somerepo.centos.org/5.10/os/x86_32/

These would then be referenced in a yum configuration file using variables:

http://somerepo.centos.org/centos/$releasever/os/$basearch/

Unfortunately these are collections of yum repositories, they aren't yum repositories in and of themselves. So you can't set something like this up in Nexus, since Nexus does not support hierarchical repository structures in yum.

One way I can think of doing this in Nexus as it stands today would be to make separate repositories for each arch/os-version, and encode the variables in the repository ID's:

http://localhost:8081/nexus/content/repositories/somerepo-5.10-x86_64

And in yum configuration use:

http://localhost:8081/nexus/content/repositories/somerepo-$releasever-$basearch

Regards,

Rich



--
You received this message because you are subscribed to the Google Groups "Nexus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nexus-users...@glists.sonatype.com.
To post to this group, send email to nexus...@glists.sonatype.com.
To view this discussion on the web visit https://groups.google.com/a/glists.sonatype.com/d/msgid/nexus-users/CADAtCpAyVOoBkZ23XJ7ayWH7sUc0pUCudqGnEq8mez9h7Kfn-w%40mail.gmail.com.
For more options, visit https://groups.google.com/a/glists.sonatype.com/d/optout.

Leonard Basuino

unread,
Jul 11, 2016, 2:08:33 PM7/11/16
to Rich Seddon, nexus...@glists.sonatype.com
Could Yum: Generate Metadata - Aliases be useful for this?  Was wondering if the artifacts could still be in the same Nexus repo but then selected/filtered out?  This may work if aliases supported wildcards, say for example, the version for all RHEL6 rpms had <version>.el6 and those for RHEL7 has <version>.el7.  Still have to deal with the 32 vs. 64 bit which is specified in the classifier (for example).
 
TIA!
Lenny
Reply all
Reply to author
Forward
0 new messages