Objective of this article is to explain about Docker Desktop which is also known as Docker for Windows or Mac, Docker Enterprise and Docker Hub.
What is Docker Desktop?
Docker Desktop is also known as Docker for Windows/Mac. Docker desktop is the Community Edition(CE) of Docker and it’s designed to run on Windows 10 & Mac OS. Docker desktop provides an Easy-to-use development environment for building, shipping and running Docker containers. For more information about how to setup Docker Desktop, Click Here
Note: Docker desktop or Docker for windows will not compatible on below Windows-10 version. It may cause problems while installing or running containers in prior windows-10 version. So, make sure you are using Windows-10 version.
What is Docker Enterprise?
Docker Enterprise is the Enterprise Edition(EE) of Docker and it’s designed to run on Windows & Linux OS. Docker Enterprise Edition is paid and good to use when we are using multi-OS, multi-Linux or multi-cloud environments.
As per official Docker blog, Docker Enterprise Edition (EE) is the only platform that manages and secures applications on Kubernetes(K8s) in multi-Linux, multi-OS and multi-cloud customer environments. As a complete platform that integrates and scales with your organization, Docker Enterprise Edition gives you the most flexibility and choice over the types of applications supported, general used, and where it’s deployed.
What is Docker hub?
Docker hub is nothing like a app store/market place of docker container images. Docker hub is also known as Cloud-based application registry and development team collaboration services. We can access docker hub by using the below URL.
Docker Toolbox is for older Mac and Windows systems that do not meet the requirements of Docker Desktop for Mac and Docker Desktop for Windows. Mostly windows Home edition doesn’t support Docker Desktop.
Please follow below link to install docker tool box in windows :
Details: 00:00:01.943299 Power up failed (vrc=VERR_SUPDRV_NO_RAW_MODE_HYPER_V_ROOT, rc=E_FAIL (0X80004005))
Looks like something went wrong in step ´Checking status on default´… Press any key to continue…
Resolution :
The above error is because of Hyper Vision . We need to enable HyperVision in windows with the below steps:
->Run a command prompt as administrator and execute:
dism /Online /Disable-Feature:Microsoft-Hyper-V
Note : For some cases ,you will get Feature name Microsoft-Hyper-V is unknown. when you trying to disable Hyper-V from Powershell. Please run below command
DISM /Online /Disable-Feature:HypervisorPlatform
->Reboot windows and type below in command prompt /powershell as admin.
bcdedit /set hypervisorlaunchtype off
If the above issue is not resolved after enabling hypervision then please follow below steps
-> Open C:\Program Files\Docker Toolbox
when docker toolbox was installed it should be as “${DOCKER_MACHINE}” create -d virtualbox $PROXY_ENV “${VM}”
-> Run bcdedit in powershell as admin mode,If hyper vision launcher type status OFF then its fine. If it is AUTO then run bcdedit /set hypervisorlaunchtype off to change status to OFF.
Objective: The objective of this article to understand how to setup Jenkins container from the Docker Kitematic dashboard. This will also give you an overview of how can we create, start, stop and delete any containers from Docker Kitematic.
Details: Jenkins is one of the tools which is most commonly using across the IT industry as part of the project CI/CD process. CI/CD stands for Continuous Integration / Continuous Deployment. The main agenda of this post to make you understand how easy of installing the Jenkins container by using Docker Kitematic.
As we already explained in the previous post, Docker Kitematic is a Graphical tool to manage different docker containers that exist in Docker. So as part of this post, we will not use any Command Line Interface(CLI).
Prior to the continuation of this article, make sure you have installed Kitematic in Docker. If you have not installed, follow the steps which are explained in Docker Kitematic installation in Windows 10.
Create a Container: Step 1: The above diagram represents the official Jenkins Docker image in the Docker Kitematic dashboard along with other images like ghost, Redis, Solr, elasticsearch, etc. Click on the CREATE button to download the Jenkins docker image. If we need to pull the Jenkins docker image from DockerHub, we need to use the below command, but as part of Kitematic, we are not executing any of the commands explicitly.
docker pull jenkins
Start Container: Step 2: You will be shown the download progress page, let’s wait until the download completes. And it automatically starts the Container as on when the download completes. You can observe the Jenkins container startup logs in below,
Running from: /usr/share/jenkins/jenkins.war
webroot: EnvVars.masterEnvVars.get("JENKINS_HOME")
Oct 08, 2019 6:00:56 PM Main deleteWinstoneTempContents
WARNING: Failed to delete the temporary Winstone file /tmp/winstone/jenkins.war
Oct 08, 2019 6:00:57 PM org.eclipse.jetty.util.log.JavaUtilLog info
INFO: Logging initialized @3721ms
Oct 08, 2019 6:00:57 PM winstone.Logger logInternal
INFO: Beginning extraction from war file
Oct 08, 2019 6:01:03 PM org.eclipse.jetty.util.log.JavaUtilLog warn
WARNING: Empty contextPath
Oct 08, 2019 6:01:03 PM org.eclipse.jetty.util.log.JavaUtilLog info
INFO: jetty-9.2.z-SNAPSHOT
Oct 08, 2019 6:01:07 PM org.eclipse.jetty.util.log.JavaUtilLog info
INFO: NO JSP Support for /, did not find org.eclipse.jetty.jsp.JettyJspServlet
Jenkins home directory: /var/jenkins_home found at: EnvVars.masterEnvVars.get("JENKINS_HOME")
Oct 08, 2019 6:01:10 PM org.eclipse.jetty.util.log.JavaUtilLog info
INFO: Started w.@47404bea{/,file:/var/jenkins_home/war/,AVAILABLE}{/var/jenkins_home/war}
Oct 08, 2019 6:01:11 PM org.eclipse.jetty.util.log.JavaUtilLog info
INFO: Started ServerConnector@1c80e49b{HTTP/1.1}{0.0.0.0:8080}
Oct 08, 2019 6:01:11 PM org.eclipse.jetty.util.log.JavaUtilLog info
INFO: Started @17405ms
Oct 08, 2019 6:01:11 PM winstone.Logger logInternal
INFO: Winstone Servlet Engine v2.0 running: controlPort=disabled
Oct 08, 2019 6:01:14 PM jenkins.InitReactorRunner$1 onAttained
INFO: Started initialization
Oct 08, 2019 6:01:14 PM jenkins.InitReactorRunner$1 onAttained
INFO: Listed all plugins
Oct 08, 2019 6:01:22 PM jenkins.InitReactorRunner$1 onAttained
INFO: Prepared all plugins
Oct 08, 2019 6:01:22 PM jenkins.InitReactorRunner$1 onAttained
INFO: Started all plugins
Oct 08, 2019 6:01:22 PM jenkins.InitReactorRunner$1 onAttained
INFO: Augmented all extensions
Oct 08, 2019 6:01:28 PM jenkins.InitReactorRunner$1 onAttained
INFO: Loaded all jobs
Oct 08, 2019 6:01:29 PM hudson.model.AsyncPeriodicWork$1 run
INFO: Started Download metadata
Oct 08, 2019 6:01:29 PM jenkins.util.groovy.GroovyHookScript execute
INFO: Executing /var/jenkins_home/init.groovy.d/tcp-slave-agent-port.groovy
Oct 08, 2019 6:01:31 PM jenkins.InitReactorRunner$1 onAttained
INFO: Completed initialization
Oct 08, 2019 6:01:32 PM org.springframework.context.support.AbstractApplicationContext prepareRefresh
INFO: Refreshing org.springframework.web.context.support.StaticWebApplicationContext@4b266244: display name [Root WebApplicationContext]; startup date [Tue Oct 08 18:01:32 UTC 2019]; root of context hierarchy
Oct 08, 2019 6:01:32 PM org.springframework.context.support.AbstractApplicationContext obtainFreshBeanFactory
INFO: Bean factory for application context [org.springframework.web.context.support.StaticWebApplicationContext@4b266244]: org.springframework.beans.factory.support.DefaultListableBeanFactory@6362a49e
Oct 08, 2019 6:01:32 PM org.springframework.beans.factory.support.DefaultListableBeanFactory preInstantiateSingletons
INFO: Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@6362a49e: defining beans [authenticationManager]; root of factory hierarchy
Oct 08, 2019 6:01:34 PM org.springframework.context.support.AbstractApplicationContext prepareRefresh
INFO: Refreshing org.springframework.web.context.support.StaticWebApplicationContext@6d93e090: display name [Root WebApplicationContext]; startup date [Tue Oct 08 18:01:34 UTC 2019]; root of context hierarchy
Oct 08, 2019 6:01:34 PM org.springframework.context.support.AbstractApplicationContext obtainFreshBeanFactory
INFO: Bean factory for application context [org.springframework.web.context.support.StaticWebApplicationContext@6d93e090]: org.springframework.beans.factory.support.DefaultListableBeanFactory@7a6e32a5
Oct 08, 2019 6:01:34 PM org.springframework.beans.factory.support.DefaultListableBeanFactory preInstantiateSingletons
INFO: Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@7a6e32a5: defining beans [filter,legacy]; root of factory hierarchy
Oct 08, 2019 6:01:35 PM jenkins.install.SetupWizard init
INFO:
*************************************************************
*************************************************************
*************************************************************
Jenkins initial setup is required. An admin user has been created and a password generated.
Please use the following password to proceed to installation:6ad6a1bd484844a690881ad01a1b8878This may also be found at: /var/jenkins_home/secrets/initialAdminPassword
*************************************************************
*************************************************************
*************************************************************
--> setting agent port for jnlp
--> setting agent port for jnlp... done
Oct 08, 2019 6:01:50 PM hudson.model.UpdateSite updateData
INFO: Obtained the latest update center data file for UpdateSource default
Oct 08, 2019 6:01:51 PM hudson.model.DownloadService$Downloadable load
INFO: Obtained the updated data file for hudson.tasks.Maven.MavenInstaller
Oct 08, 2019 6:01:56 PM hudson.model.DownloadService$Downloadable load
INFO: Obtained the updated data file for hudson.tools.JDKInstaller
Oct 08, 2019 6:01:56 PM hudson.model.AsyncPeriodicWork$1 run
INFO: Finished Download metadata. 27,079 ms
Oct 08, 2019 6:01:58 PM hudson.model.UpdateSite updateData
INFO: Obtained the latest update center data file for UpdateSource default
Oct 08, 2019 6:01:58 PM hudson.WebAppMain$3 run
INFO: Jenkins is fully up and running
As per the above logs, we can understand, downloading Jenkins metadata is finished and Jenkins is fully up and running. We can also observe that from the highlighted lines, Jenkins is created the admin user to access and do the initial setup of Jenkins with the encrypted password.
Below is the normal command which we will use to run the docker container. In this case, we are using the Jenkins image to run as a container in Docker.
docker run -it -p 8080:8080 Jenkins
How can I access Jenkins? By default, Docker Jenkins will use 8080(Not exposed) port so make sure there are no other processes are using the same port. We can’t directly access the Jenkins with the port of 8080 when we are running from Docker Kitematic. This 8080 port is internally mapped to some other host:port which is exposed to the outside world. We can find that information under the Settings ==> Hostname/Port as shown in the below image,
As on when we hit the localhost:32779 from any of the browsers, we can see the below screen.
What is the default Jenkins admin password? There are 2 ways to find the password. 1. You can find it from the Jenkins Container startup logs as shown in the above. 2. Click on /var/jenkins_home under the Volumes to extract the war file content. You can also find the password from the below path after volume(war) extraction completes.
Jenkins Customization page: As on when we successfully authenticated, we will be shown a page called Jenkins Customization page. Look at the below snapshot,
As on when I choose the Install Suggested plugins option from the above screen, Jenkins started installing the plugins. Please look at the plugin installation progress as shown in the below image,
If in case you get a message of saying some of the plugins are failed to install, do you want to retry or continue? better retry once or twice. If still you will be shown the same message, just ignore and choose the link of Continue. Create First Admin User:
Click on Continue as admin link from the above screen you will be shown the below screen.
Click on Start using Jenkins to see the Jenkins home page.
Now your Jenkins setup is done successfully. You can create new jobs to configure CI/CD process for your project.
How to Stop, Restart running containers in Kitematic? Stopping or restarting the running docker container is an easy process from Docker Kitematic. As shown in the below image, please click on Stop/Restart button accordingly to process the same.
How to delete the Docker container from Kitematic? As shown in the below image, you can find the DELETE CONTAINER button under the SETTINGS tab to delete any of the containers from Docker Kitematic.
I hope this will be clear. Thanks for VISITING. Happy Learning…. 🙂