diff --git a/roles/multi-node-bridge/templates/zuul-multi-node-bridge-ovs.repo.j2 b/roles/multi-node-bridge/templates/zuul-multi-node-bridge-ovs.repo.j2 index 3621474bc..796111b9c 100644 --- a/roles/multi-node-bridge/templates/zuul-multi-node-bridge-ovs.repo.j2 +++ b/roles/multi-node-bridge/templates/zuul-multi-node-bridge-ovs.repo.j2 @@ -1,5 +1,5 @@ # Vendored from rdo-release: https://github.com/rdo-infra/rdo-release -{% if ansible_distribution == 'CentOS' %} +{% if ansible_distribution in ['CentOS', 'RedHat'] and ansible_distribution_major_version|int <= 7 %} [centos-openstack-queens] name=CentOS OpenStack Queens Repository {% if zuul_site_mirror_fqdn is defined %} @@ -10,10 +10,10 @@ baseurl=http://mirror.centos.org/centos/7/cloud/$basearch/openstack-queens/ gpgcheck=1 enabled=1 gpgkey=file:///tmp/RPM-GPG-KEY-CentOS-SIG-Cloud -{% elif ansible_distribution == 'RedHat' %} +{% elif ansible_distribution == 'RedHat' and ansible_distribution_major_version|int >= 8 %} [RDO-RHEL8-deps] name=RedHat Openstack deps repo baseurl=https://trunk.rdoproject.org/rhel8-master/deps/latest/ gpgcheck=0 enabled=1 -{% endif %} \ No newline at end of file +{% endif %} diff --git a/roles/multi-node-bridge/vars/RedHat.yaml b/roles/multi-node-bridge/vars/RedHat.yaml index 1ae946d9e..6f26a79c2 100644 --- a/roles/multi-node-bridge/vars/RedHat.yaml +++ b/roles/multi-node-bridge/vars/RedHat.yaml @@ -1,3 +1,8 @@ --- -ovs_package: "rhosp-openvswitch" +ovs_package: >- + {% if ansible_distribution_major_version|int >= 8 -%} + rhosp-openvswitch + {%- else -%} + openvswitch + {%- endif %} ovs_service: "openvswitch"