#8689 Add centos platform module
Closed: fixed by frenaud. Opened by abbra.

Right now CentOS has to do manual override of the IPA platform in their spec file because we by default detect the platform from /etc/os-release content which has ID="centos" vs ID="rhel" on RHEL.

I think it is beneficial to add a centos IPA platform module, to allow 'debranding' and other tuning in it. For newer CentOS 8 replacements (AlmaLinux and RockyLinux) this also would be useful as they would be able to add their own platform modules if interested.


We also fall back to ID_LIKE. CentOS should have ID_LIKE=rhel fedora in /etc/os-release. The code in ipaplatform automatically selects rhel platform provider, since it is the first entry in ID_LIKE and ipaplatform.centos is not available. The flag./configure --with-ipaplatform overrides auto-detection.

I can confirm as recently as 4.8.7 that the auto-detection selects centos as the platform, not rhel, and fails to build.

checking supported IPA platform... configure: error: IPA platform centos is not supported

To resolve this CentOS has had to use the configure flag to force rhel as the platform. That is a manual change that has to take place every time a new SRPM is exported to git.centos.org. Our goal is to not have to perform this manual modification and be able to rebuild the RHEL SRPM on CentOS as-is. It doesn't matter to me if we do that with a centos platform module, or by changing the auto-detection to select rhel when run on CentOS.

I see. That's a limitation of our configure script. It only checks ID and does not fall back to ID_LIKE.

PR https://github.com/freeipa/freeipa/pull/5516 should fix the issue for CentOS and Ubuntu platforms.

Metadata Update from @cheimes:
- Custom field on_review adjusted to https://github.com/freeipa/freeipa/pull/5516

master:

  • 5ca918943c4614f17085a55239fdfd4796a1cb16 configure: ipaplatform falls back to ID_LIKE

ipa-4-9:

  • 55180f6e9141bca391a7e2c9d9727948624c307f configure: ipaplatform falls back to ID_LIKE

Metadata Update from @frenaud:
- Issue close_status updated to: fixed
- Issue status updated to: Closed (was: Open)

Metadata