How to uninstall docker on ubuntu?

by XDK 28. August 2019 22:11

Explanation:

To uninstall docker

sudo apt-get purge docker-ce
sudo rm -rf /var/lib/docker
Note: The output of the below command will provide you with information the installed package software, version, architecture and short description about the package. grep command is used to find the docker package
sudo dpkg --get-selections | grep docker | cut -f 1
sudo apt-get remove --purge <package name from the previous command output>
sudo whereis docker
sudo rm -rf <directory/file path from the previous command output>

Tags:

Amazon Web Service | Azure Native DevOps | Docker | Microsoft Azure Services

Containers vs Virtual Machines

by XDK 28. August 2019 09:31

Explanation:

 * Containers and virtual machines both have similar resource allocation and allocation benefits.
 * Containers and VMs are functionally different because containers virtualise the Operating System and VMs are virtualise the hardware.
 * Containers are just processes

Tags:

Amazon Web Service | Azure Native DevOps | Docker | Microsoft Azure Services

How to run a container?

by XDK 25. August 2019 17:49

Explanation:

ubuntu@ip-172-31-59-138:/opt/HelloWorld$ docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
xdk_helloworld latest a801afaa1782 20 seconds ago 473MB
tomcat jre8 3639174793ba 3 months ago 463MB

Command to run the xdk_helloworld docker image, to listen to the port 80 and route to 8080 in the container which is the tomcat's default port 8080 at runtime.

ubuntu@ip-172-31-59-138:/opt/HelloWorld$ docker run -p 80:8080 xdk_helloworld

Open http://34.204.171.134/HelloWorld/ in a browser to see the HelloWorld web is application running.

Tags:

Amazon Web Service | Azure Native DevOps | Docker | Microsoft Azure Services

Working with Docker, Docker images and containers on Ubuntu 18.04

by XDK 25. August 2019 17:41

Tags:

Amazon Web Service | Azure Native DevOps | Docker | Microsoft Azure Services

How do SSH into a running container?

by XDK 25. August 2019 17:37

Explanation:

Command to get the name of the existing container

ubuntu@ip-172-31-57-91:/opt/HelloWorld$ docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
2a41bd524e93 xdkdockerhub/xdkdockerrepo:xdk_helloworld_V1 "catalina.sh run" 5 minutes ago Up 5 minutes 0.0.0.0:80->8080/tcp sweet_hypatia

Command to get a bash shell in the container.
ubuntu@ip-172-31-57-91:/opt/HelloWorld$ docker exec -it sweet_hypatia bash

Verify with basic commands

root@2a41bd524e93:/usr/local/tomcat# ls -a

. BUILDING.txt LICENSE README.md RUNNING.txt conf lib native-jni-lib webapps
.. CONTRIBUTING.md NOTICE RELEASE-NOTES bin include logs temp work

root@2a41bd524e93:/usr/local/tomcat# ls -al
total 168
drwxr-sr-x 1 root staff 4096 May 16 00:50 .
drwxrwsr-x 1 root staff 4096 May 8 13:20 ..
-rw-r--r-- 1 root root 19539 May 4 09:22 BUILDING.txt
-rw-r--r-- 1 root root 5407 May 4 09:22 CONTRIBUTING.md
-rw-r--r-- 1 root root 57092 May 4 09:22 LICENSE
-rw-r--r-- 1 root root 1726 May 4 09:22 NOTICE
-rw-r--r-- 1 root root 3255 May 4 09:22 README.md
-rw-r--r-- 1 root root 7139 May 4 09:22 RELEASE-NOTES
-rw-r--r-- 1 root root 16262 May 4 09:22 RUNNING.txt
drwxr-xr-x 2 root root 4096 May 16 00:50 bin
drwxr-sr-x 1 root root 4096 Aug 25 11:56 conf
drwxr-sr-x 2 root staff 4096 May 16 00:50 include
drwxr-xr-x 2 root root 4096 May 16 00:49 lib
drwxrwxrwx 1 root root 4096 Aug 25 11:56 logs
drwxr-sr-x 3 root staff 4096 May 16 00:50 native-jni-lib
drwxr-xr-x 2 root root 4096 May 16 00:49 temp
drwxr-xr-x 1 root root 4096 Aug 25 11:56 webapps
drwxrwxrwx 1 root root 4096 Aug 25 11:56 work
root@2a41bd524e93:/usr/local/tomcat# exit
exit
ubuntu@ip-172-31-57-91:/opt/HelloWorld$

Tags:

Amazon Web Service | Azure Native DevOps | Docker | Microsoft Azure Services

About the author

My name is Xavier Dilip Kumar Jayaraj having 16+ years of IT experience which includes solid experience and depth Knowledge in Application Life Cycle Management, Configuration Management, Implementation and Support using TFS on-premises and Azure DevOps. I have invested in gaining DevOps knowledege to expertise with Cloud Computing providers namely Microsoft Azure and Amazon Web Services in recent years. I am very positive to learn and adapt emerging technologies to client’s environment.

Microsoft Certified: Azure Administrator Associate

Microsoft Certified: Azure DevOps Engineer Expert

DevOps Engineer Certificate Program | Transcript 

OTP-AWSD5: AWS IoT: Developing and Deploying an Internet of Things

[PCEP-30-01] PCEP – Certified Entry-Level Python Programmer

Quotes I Like

"Failure will never overtake me if my determination to succeed is strong enough."  - Dr. APJ. Abdul Kalam

"Always be yourself, express yourself, have faith in yourself, do not go out and look for a successful personality and duplicate it." - Bruce Lee

"Technology is just a tool. In terms of getting the kids working together and motivating them, the teacher is the most important." - Bill Gates

"Innovation distinguishes between a leader and a follower." - Steve Jobs

CategoryList

Disclaimer

The information provided here is based on my expreriences, troubleshooting and online/offline findings. It can be used as is on your own risk without any warranties and I impose no rights.