Restrict to OS version not matching for Almalinux

Problem:

In katello we have a product call EPEL with 2 repositories epel8 and epel7. The epel8 should only be available for RH8 nodes (centos8 for example). This works on centos but we also have some AlmaLinux 8.4 hosts where this repository does not show up.

Restrict to OS version is set to rhel-8 for the epel8 repo

Expected outcome:

The EPEL8 repo to be available on AlmaLinux 8.4

Foreman and Proxy versions:
2.3.5
Foreman and Proxy plugin versions:
2.3.5

I used Oracle Linux for a few years and now AlmaLinux, it does not work for both of them. I workaround the issue by using seperate content views for el7 and el8 and only add the correct respositorys to them.

I have the same problem for any repository not directly linked to RedHat. Is there any progress on this issue? In the code of katello (forgive me for not learning ruby properly) it seems there is no way of marking a repository as matching a OS major version for dependency checking. Is this really a RedHat feature only? I am surprised there are no matches for debian or Suse major versions either.

Restrict to OS version only works with RHEL, not RHEL derivatives. For more info on why, see [RFC] Making things easier when working with custom products & Simple Content Access (SCA) - #18 by jeremylenz