Published 5月 25, 2019 by with 0 comment

1 - 01 - Install Docker On Ubuntu



In this lab, I run a VM which is  installed Ubuntu-16.04.6.
And install Docker Community Edition (CE) on Ubuntu.

1. In the Docker doc, install docker need 64 bit OS.
I use ubuntu-16.04.6-desktop-amd64.iso this verion.
URL: http://releases.ubuntu.com/16.04/

2. After OS install finish, install SSH service. Before install Docker does not need install SSH but use SSH to remote connect is very important.
$ sudo apt-get install openssh-server -y

3. Using SSH to remote connect my Ubuntu.
$ ssh username@ip_address

4. Update the package
$ sudo apt-get update



5. Install packages to allow apt to use a repository over HTTPS:
$ sudo apt-get install \
    apt-transport-https \
    ca-certificates \
    curl \
    gnupg-agent \
    software-properties-common



6. Add Docker’s official GPG key:
$ curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -


   
7. Verify that you now have the key.
$ sudo apt-key fingerprint 0EBFCD88



8. Add the Docker source to /etc/apt/sources.list
$ sudo add-apt-repository \
   "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
   $(lsb_release -cs) \
   stable"



9. Update the package again
$ sudo apt-get update



10. Install the latest version of Docker CE and containerd.
$ sudo apt-get install docker-ce docker-ce-cli containerd.io



11. Verify:
$ systemctl status docker.service



Resource:
1. Get Docker CE for Ubuntu
https://docs.docker.com/install/linux/docker-ce/ubuntu/


最初發表 / 最後更新: 2019.05.25 / 2019.05.25

0 comments:

張貼留言