Unable to install docker on Ubuntu 14.04.5 LTS (GNU/Linux 4.2.0-27-generic x86_64)

I am trying to install docker on linux machine “Ubuntu 14.04.5 LTS (GNU/Linux 4.2.0-27-generic x86_64)” on this version I am trying to install docker with installation steps as per docker.com.

When I am trying to run the command “sudo apt-get install docker-ce docker-ce-cli containerd.io” I am getting the below error:
Reading package lists… Done
Building dependency tree
Reading state information… Done
E: Unable to locate package docker-ce-cli
?
Need solution for this ?

is it necessary to install docker ce-cli and containerd ??

sudo apt-get install docker-ce containerd.io

I had another problem while installing the above command.on same machine Ubuntu 14.04 version
I am getting below error:

sudo apt-get install docker-ce containerd.io.
Reading package lists… Done
Building dependency tree
Reading state information… Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
containerd…io : Depends: libseccomp2 (>= 2.3.0) but 2.1.1-1ubuntu1~trusty5 is to be installed
E: Unable to correct problems, you have held broken packages.

Is there any solution for this or should I run only sudo apt-get install docker-ce instead of sudo apt-get install docker-ce containerd…io ?? Is containerd…io will cover under docker-ce input.

I’m afraid I don’t know the commands on ubuntu, but on Redhat/Centos, you need to install docker-ce and then containerd.io separately.

sudo dnf install --nobest docker-ce

sudo dnf install https://download.docker.com/linux/centos/7/x86_64/stable/Packages/containerd.io-1.2.6-3.3.el7.x86_64.rp

This skips the problematic containerd dependency and then you install it as a standalone installation.