Set up the repository

You only need to set up the repository once, after which you can install MCR from the repository and upgrade as needed. MCR supports RHEL 64-bit version 7.4 and higher running on x86_64.

Note

MCR supports the overlay2 storage drivers on RHEL. The following limitations apply:

  • If you enable selinux, MCR supports overlay2 on RHEL 7.4 and higher (OverlayFS).

  • If you disable selinux, MCR supports overlay2 on RHEL 7.2 and higher, with kernel version 3.10.0-693 and higher.


Set up the repository for RHEL 7

  1. Remove existing Docker repositories from /etc/yum.repos.d/:

    sudo rm /etc/yum.repos.d/docker*.repo
    
  2. Store https://repos.mirantis.com in an environment variable:

    export DOCKERURL="https://repos.mirantis.com"
    
  3. Store the value of DOCKERURL using a yum variable in /etc/yum/vars/:

    sudo -E sh -c 'echo "$DOCKERURL/rhel" > /etc/yum/vars/dockerurl'
    
  4. Store your OS version string in /etc/yum/vars/dockerosversion. Use 7 or include the minor version starting with 7.2:

    sudo sh -c 'echo "<version>" > /etc/yum/vars/dockerosversion'
    
  5. Install the yum-utils that provides the yum-config-manager utility:

    sudo yum install -y yum-utils
    
  6. Enable the extras RHEL repository to ensure access to the container-selinux package that docker-ee requires:

    sudo yum-config-manager --enable rhel-7-server-extras-rpms
    
    sudo yum-config-manager --enable extras
    sudo subscription-manager repos \
    --enable=rhel-7-for-power-le-extras-rpms
    sudo yum makecache fast
    sudo yum -y install container-selinux
    
  7. Enable another repository for AWS and Azure:

    sudo yum-config-manager --enable rhel-7-server-rhui-extras-rpms
    
    sudo yum-config-manager --enable rhui-rhel-7-server-rhui-extras-rpms
    
  8. Add the stable MCR repository:

    sudo -E yum-config-manager \
    --add-repo \
    "$DOCKERURL/rhel/docker-ee.repo"
    

Set up the repository for RHEL 8

  1. Remove existing Docker repositories from /etc/yum.repos.d/:

    sudo rm /etc/yum.repos.d/docker*.repo
    
  2. Store https://repos.mirantis.com in an environment variable.

    export DOCKERURL="https://repos.mirantis.com"
    
  3. Store the value of DOCKERURL using a yum variable in /etc/yum/vars/:

    sudo -E sh -c 'echo "$DOCKERURL/rhel" > /etc/yum/vars/dockerurl'
    
  4. Store your OS version string in /etc/yum/vars/dockerosversion. Use 8:

    sudo sh -c 'echo "<version>" > /etc/yum/vars/dockerosversion'
    
  5. Install the yum-utils that provides the yum-config-manager utility:

    sudo yum install -y yum-utils
    
  6. Add the stable MCR repository:

    sudo -E yum-config-manager \
    --add-repo \
    "$DOCKERURL/rhel/docker-ee.repo"