Skip to content
Snippets Groups Projects
Commit 4a79ce40 authored by Steven Dake's avatar Steven Dake
Browse files

Make RHEL build from source

This patch enables building from source in RHEL.  It works by making
the repositoroies specific to RHEL7 run in either from source or
from binary/rhos builds.

Change-Id: I795284cccc87c4a87d58c93ec73b3f9ea08878f2
Partially-Implements: blueprint rhel-based-image-support
parent 7740c2aa
No related branches found
No related tags found
No related merge requests found
...@@ -14,6 +14,15 @@ COPY mariadb.yum.repo /etc/yum.repos.d/MariaDB.repo ...@@ -14,6 +14,15 @@ COPY mariadb.yum.repo /etc/yum.repos.d/MariaDB.repo
RUN yum install -y http://www.percona.com/redir/downloads/percona-release/redhat/0.1-3/percona-release-0.1-3.noarch.rpm \ RUN yum install -y http://www.percona.com/redir/downloads/percona-release/redhat/0.1-3/percona-release-0.1-3.noarch.rpm \
&& sed -i 's|$releasever|centos/latest|g' /etc/yum.repos.d/percona-release.repo && sed -i 's|$releasever|centos/latest|g' /etc/yum.repos.d/percona-release.repo
{% if base_distro == 'rhel' %}
# Turn on EPEL, rhel7-extras, and rhel7-optional throughout all builds for RHEL
RUN yum install -y \
https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm \
&& subscription-manager repos --enable rhel-7-server-optional-rpms \
&& subscription-manager repos --enable rhel-7-server-extras-rpms \
&& yum clean all
{% endif %}
{% if install_type == 'binary' %} {% if install_type == 'binary' %}
{% if base_distro in ['centos', 'oraclelinux', 'rhel'] %} {% if base_distro in ['centos', 'oraclelinux', 'rhel'] %}
...@@ -41,14 +50,6 @@ RUN yum install -y \ ...@@ -41,14 +50,6 @@ RUN yum install -y \
RUN yum-config-manager --enable ol7_optional_latest ol7_addons RUN yum-config-manager --enable ol7_optional_latest ol7_addons
{% endif %} {% endif %}
{% if base_distro == 'rhel' %}
RUN yum install -y \
https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm \
&& subscription-manager repos --enable rhel-7-server-optional-rpms \
&& subscription-manager repos --enable rhel-7-server-extras-rpms \
&& yum clean all
{% endif %}
# Endif for base_distro centos/oraclelinux # Endif for base_distro centos/oraclelinux
{% elif base_distro == 'fedora' %} {% elif base_distro == 'fedora' %}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment