In this tutorial, you will learn about docker containers, creating docker images and push the docker images to Docker Hub(hub.docker.com/)registry.
What is docker and what is a container ?
Docker is a tool, which allows deploying the applications in a container to run on the host operating system.
Container allows developer to package an application with all the required modules into a single standard unit.
Containers shares the resources in the operating system where for virtual machines need to allocate the resources.
Here am going to explain with hello world application using nodejs.
The command used to build the image using dockerfile.
docker build -t dockerhub-username/container-name
Below command is used to run the container after generating the img from the dockerfile.
docker run -p 3000:3000 dockerhub-username/container-name
Push the docker image to Docker Hub.
Login into the docker
docker push dockerhub-username/container-name
I have created a simple hello world app using nodejs. Deploying the application with dockerfile and the docker commands.
https://github.com/SrinivasNidadavolu/docker-nodejs-dockerhub
What is docker and what is a container ?
Docker is a tool, which allows deploying the applications in a container to run on the host operating system.
Container allows developer to package an application with all the required modules into a single standard unit.
Containers shares the resources in the operating system where for virtual machines need to allocate the resources.
Here am going to explain with hello world application using nodejs.
The command used to build the image using dockerfile.
docker build -t dockerhub-username/container-name
Below command is used to run the container after generating the img from the dockerfile.
docker run -p 3000:3000 dockerhub-username/container-name
Push the docker image to Docker Hub.
Login into the docker
docker push dockerhub-username/container-name
I have created a simple hello world app using nodejs. Deploying the application with dockerfile and the docker commands.
https://github.com/SrinivasNidadavolu/docker-nodejs-dockerhub
0 coment�rios:
Post a Comment