Install Mirantis Container Runtime for Ubuntu¶
You can install Mirantis Container Runtime (MCR) either through the use of a repository, or by downloading and installing DEB packages.
Install and upgrade MCR from a repository¶
Mirantis recommends that you install MCR from our Docker repository using APT, the Ubuntu package manager. This method provides a level of automation with the MCR dependencies installation and updates automation.
Note
It is not necessary to uninstall older versions of Docker or Mirantis Container Runtime prior to upgrading as package conflicts are resolved automatically by APT.
Set up the repository¶
You only need to set the repository up once. After doing so, you can install MCR from the repo and repeatedly upgrade the software as necessary.
Install the necessary packages for setting up the repository:
sudo apt update && sudo apt install curl gnupg
Import the GPG key:
sudo gpg --batch --yes \ --output /usr/share/keyrings/mirantis-archive-keyring.pgp --dearmor \ <<< $(curl -fsSL https://repos.mirantis.com/ubuntu/gpg)
Verify that the GPG key has the fingerprint
DD91 1E99 5A64 A202 E859 07D6 BC14 F10B 6D08 5F96
:$ gpg --show-keys --with-fingerprint --keyid-format=short \ /usr/share/keyrings/mirantis-archive-keyring.pgp
Expected output:
pub rsa4096/6D085F96 2017-02-22 [SCEA] Key fingerprint = DD91 1E99 5A64 A202 E859 07D6 BC14 F10B 6D08 5F96 uid Docker Release (EE deb) <docker@docker.com> sub rsa4096/91A29FA3 2017-02-22 [S]
Add the repository to your
sources.list
. To do this, create a text file in/etc/apt/sources.list.d/mirantis.sources
:Types: deb URIs: https://repos.mirantis.com/ubuntu Suites: <value-depends-on-Ubuntu-version> Architectures: amd64 Components: <determines-update-channel> Signed-by: /usr/share/keyrings/mirantis-archive-keyring.pgp
Note
The
Suites
parameter setting isjammy
for Ubuntu 22.04 andfocal
for Ubuntu 20.04.The
Components
parameter setting sets the update channel, which determines which MCR releases will be available for installation and upgrade. The value for the latest MCR 25.0.x patch isstable-25.0
and the value for the latest MCR 25.0.x patch with the FIPS-mode variant isstable-25.0/fips
.
Install from the repository¶
Run the following command to install MCR from the repository:
sudo apt update && sudo apt install docker-ee
Any existing MCR installation is replaced.
Upgrade from the repository¶
Run apt update && apt upgrade to keep your MCR installation up to date with the latest MCR release that is available in the update channel you selected during the repository setup.
Install and upgrade MCR from a package¶
If for some reason you cannot use the repository MCR install method, you can
perform manual installation with the .deb
package files for
your release. Be aware, though, that you will need to download new packages
each time you want to upgrade MCR.
Install from a package¶
Download the
.deb
packages for your Ubuntu version from the release-notes.Install MCR.
sudo dnf install path/to/downloaded/packages/*.deb
Upgrade from a package¶
Download the newer
.deb
packages for your Ubuntu version.Upgrade MCR.
sudo dnf install path/to/downloaded/packages/*.deb
Initial setup¶
On installation, the Docker service starts automatically and is configured to
start thereafter at boot up. The docker
group is created, but without any
users added to the group.
Run the hello-world
image to verify that MCR is correctly installed. This
command downloads a test image, runs it in a container, prints an informational
message, and exits:
sudo docker run hello-world
Important
Use sudo
to run docker
commands. For information on how to allow
non-privileged users to run docker commands, refer to the official Docker
documentation Manage Docker as a non-root user.
Uninstall Mirantis Container Runtime¶
Uninstall the Mirantis Container Runtime package.
sudo apt purge docker-ee
Delete all images, containers, and volumes, as these are not automatically removed from your host:
sudo rm -rf /var/lib/docker
Delete all other Docker-related resources:
sudo rm -rf /run/docker /var/run/docker /etc/docker
Manually delete any edited configuration files.