Sunday, December 3, 2017

How To Install and Use Docker on Ubuntu 16.04 


Introduction

Docker is an application that makes it simple and easy to run application processes in a container, which are like virtual machines, only more portable, more resource-friendly, and more dependent on the host operating system.


Step 1 — Installing Docker

The Docker installation package available in the official Ubuntu 16.04 repository may not be the latest version. To get the latest and greatest version, install Docker from the official Docker repository. This section shows you how to do just that.
First, add the GPG key for the official Docker repository to the system:
  • curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
Add the Docker repository to APT sources:
  • sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
Next, update the package database with the Docker packages from the newly added repo:
  • sudo apt-get update 
Finally, install Docker:
  • sudo apt-get install -y docker-ce
Docker should now be installed, the daemon started, and the process enabled to start on boot. Check that it's running:
  • sudo systemctl status docker 
 

Step 2 — Executing the Docker Command Without Sudo (Optional)

By default, running the docker command requires root privileges — that is, you have to prefix the command with sudo. It can also be run by a user in the docker group, which is automatically created during the installation of Docker. If you attempt to run the docker command without prefixing it with sudo or without being in the docker group, you'll get an output like this:

Output
docker: Cannot connect to the Docker daemon. Is the docker daemon running on this host?. See 'docker run --help'.
 
If you want to avoid typing sudo whenever you run the docker command, add your username to the docker group:
  • sudo usermod -aG docker ${USER}

Thursday, November 23, 2017

Installing Ubuntu 16.04


1.REQUIREMENTS
You'll need to consider the following before starting the installation.

  • Connect your laptop to a power source
  • Ensure you have at least 5GB of free storage
  • Have access to either a DVD or a USB flash drive containing the version of ubuntu you want to install
  • you can boot from DVD or Flash drive easily.
2.PREPARE TO INSTALL 


3.ALLOCATE DRIVE SPACES

Please be careful when allocating drives. As a best practice i used to allocate 4GB for Swap area. and the Rest drive spaces from root and home.


4. Begin the installation


5. Fine Tuning

Before the installation you have to follow the following instructions.



  • Set Time zone
  • Select your preferred keyboard Layout
  • Fill your login details Note:your account will be created using those details :)
  • After that it will start the installation. 
  • Finish the installation and Reboot