Clear Containers 2.1 is available for Ubuntu* for versions 16.04, 16.10 and 17.04. Clear Containers supports the latest version of Docker* CE, currently 17.05, with the exception of Swarm*. If you require Swarm, install Docker version 1.12.1.
This step is optional and only required in case Docker is not installed on the system or an specific version of Docker is required.
Execute the commands for only one of the two following options.
The add-apt-repository
and apt-get
commands below reference
ubuntu-xenial
. Both Ubuntu 16.04 and 16.10 require this reference
since the version of Docker supported by Clear Containers is not
available as a Ubuntu 16.10 package.
sudo groupadd docker
sudo -E gpasswd -a $USER docker
sudo apt-get install -y apt-transport-https ca-certificates
curl -fsSL https://yum.dockerproject.org/gpg | sudo apt-key add -
sudo add-apt-repository "deb https://apt.dockerproject.org/repo/ ubuntu-xenial main"
sudo apt-get update
sudo apt-get install -y --allow-downgrades docker-engine=1.12.1-0~xenial
sudo apt-mark hold docker-engine
Caution: Clear Containers 2.1 and Swarm will not work correctly on Docker 17.
sudo apt-get install \
apt-transport-https \
ca-certificates \
curl \
software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo add-apt-repository \
"deb [arch=amd64] https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) \
stable"
sudo apt-get update
sudo apt-get install docker-ce
For more information on installing Docker please refer to the Docker Guide
sudo sh -c "echo 'deb http://download.opensuse.org/repositories/home:/clearlinux:/preview:/clear-containers-2.1/xUbuntu_$(lsb_release -rs)/ /' >> /etc/apt/sources.list.d/cc-oci-runtime.list"
curl -fsSL http://download.opensuse.org/repositories/home:/clearlinux:/preview:/clear-containers-2.1/xUbuntu_$(lsb_release -rs)/Release.key | sudo apt-key add -
sudo apt-get update
sudo apt-get install -y cc-oci-runtime
sudo mkdir -p /etc/systemd/system/docker.service.d/
cat << EOF | sudo tee /etc/systemd/system/docker.service.d/clr-containers.conf
[Service]
ExecStart=
ExecStart=/usr/bin/dockerd -D --add-runtime cor=/usr/bin/cc-oci-runtime --default-runtime=cor
EOF
sudo systemctl daemon-reload
sudo systemctl restart docker
sudo systemctl enable cc-proxy.socket
sudo systemctl start cc-proxy.socket
You are now ready to run Clear Containers. For example:
sudo docker run -ti fedora bash