E N D
What is Docker? Docker is an open platform for developing, shipping, and running applications. Docker enables you to separate your applications from your infrastructure so you can deliver software quickly. With Docker, you can manage your infrastructure in the same ways you manage your applications. By taking advantage of Docker's methodologies for shipping, testing, and deploying code, you can significantly reduce the delay between writing code and running it in production. install Apps store download java .apk java jar (runtime environment) Pack and make image Docker Hub Running in container Download
DockerArchitecture Docker Client: The starting point of Docker Provides a way for users to interact with Docker. Docker Daemon: Taskmaster on the scene! Runs on the host machine and handles all requests from the Docker client, such as building, running, and distributing Docker containers. Docker Image: Your application’s blueprint. Docker Images are read-only templates that form the basis of containers. Docker Container: Running instances of Docker images. A Docker container holds everything needed to run an application — the code, runtime, libraries, environment variables, and configuration files. Docker Registry: Like a library for Docker Images! The Docker registry is where Docker images live. Docker Hub is a public registry that anyone can use, but you also have the option of creating your own private registry. https://medium.com/@saddy.devs/understanding-docker-architecture-934ecd042b5f
How does Dockerwork? Container i Container 1 Container 2 Container n Server-end Docker Daemon Client 1 Client 2 Client j Client n Client-end Host Computer
How does Dockerrun a new container from image “HelloWorld”? uses this image and runs it. Y Docker first searches for the image locally downloads the image to the local environment. Start checks whether the image is available locally. checks whether it’s available on Docker Hub Y N downloads the image from Docker Hub. N If the image is not found, it returns an error.
Common Docker Commands (necessary to learn) BasicCommands docker version # Show the Docker version information docker info # Display system-wide information ImageCommands docker images # List images, show all top level images, their repository and tags, and their size. docker search # Search Docker Hub for images docker pull # Download an image from a registry docker rmi # Remove one or more images ContainerCommands docker run # Create and run a new container from an image docker ps # List containers docker rm # Remove one or more containers OtherCommands docker logs [OPTIONS] # print logs docker top [container-ID] # View process information in the container docker inspect [container-ID] # View container metadata dockerexec-it [container-ID] # Access the currently running container (open a new terminal) docker attach [container-ID] # Access the currently running container (access the running terminal) docker cp [container-ID]:[container-path] [target-host-path] # copy file from container to target host
https://hub.docker.com Docker Resource: Docker Hub
https://docs.docker.com Docker Resource: Official Documents