2

I'm relatively inexperienced with Linux, other than the basics. But my company have asked me to find a way to setup a repository hosted on Ubuntu for rpm & and deb packages. Now I've finally managed to get a public apt repository working for the deb packages, but cannot work out a way to do it for RPM packages. especially since Createrepo is no longer being distributed for Ubuntu 20.04.

Some suggestions I've seen are to just setup a VM of Fedora etc and make the repository there, then just copy the files over to ubuntu. But Would that work? is there a better way to do it?

We've considered using a package hoster but my employer would still prefer that we host them ourselves. at least for now.

Any help would be much appreciated.

kenny608uk
  • 21
  • 4
  • Apologies @guiverc I did mean 20.04. My mistake – kenny608uk Dec 21 '20 at 23:20
  • @Rinzwind its required for clients who aren't using ubuntu. We're just hosting it there. But the packages are for a variety of OS's. RHEL/CENTOS, Raspbian etc. – kenny608uk Dec 22 '20 at 00:31
  • 1
    Ok valid reason but do that then from a redhat server. Or set it up such that you can create DEB packages using `alien` . Using rpm in Ubuntu will be a disaster. "Some suggestions I've seen are to just setup a VM of Fedora etc and make the repository there, then just copy the files over to ubuntu. " this sort of: don't copy them to Ubuntu; connect the redhat systems to this VM so they directly update through that repository. – Rinzwind Dec 22 '20 at 01:15
  • @Rinzwind thank you, Maybe I'll end up building it on CentOS for both. We'll see what happens. – kenny608uk Dec 22 '20 at 17:08
  • I'm trying to build the repos on a CI. Currently, I can still specify Ubuntu 18.04 as the host but at some point, this will change and we'll need a better solution. Any ideas what to do? Also, I suggest using Ubuntu 18.04 that has the createrepo package – Felipe Feb 12 '21 at 22:27

1 Answers1

0

I too was bitten by the unavailability of createrepo(-c) on Ubuntu 20.04. I think the old createrepo tool used to be available and got removed, because it was installed prior to upgrading to Ubuntu 20.04.2. Anyway, the solution I chose to pursue was to package it for GNU Guix, a distribution agnostic package manager. Provided you have it installed (see: https://guix.gnu.org/manual/en/html_node/Installation.html) and up-to-date (using guix pull), you should be able to:

$ guix install createrepo-c
[...]
$ createrepo_c --version
Version: 0.17.4 (Features: LegacyWeakdeps )

On top of Ubuntu 20.04, or any other GNU/Linux distribution for what it's worth.

Apteryx
  • 439
  • 5
  • 7