UNIVISION11 / DEVOPS

0 stars 2 forks source link

Please add basic Docker commands #3

Closed vijayendrareddy5 closed 3 years ago

vijayendrareddy5 commented 3 years ago

docker pull docker images docker ps -a

pavanil commented 3 years ago

docker stop docker start docker ps docker pause

vijayendrareddy5 commented 3 years ago

!/bin/bash

echo "This command used for display the version" sudo docker --version echo "It will be display current images" sudo docker images echo "The docker pull command serves for downloading Docker images from a registry, pulls images from Docker Hub"
sudo docker pull ubuntu/httpd/jenkins/mysql/redis/nginx echo "Display all images names"
sudo docker images echo "Run the image"
sudo docker run -it -d ubuntu/httpd/jenkins/mysql/redis/nginx echo "It will be running the image in our localhost" sudo docker run --name mynginx -p 80:80 -d nginx echo "Most Linux distributions use systemctl to start services. If you do not have systemctl , use the service command. systemctl" sudo systemctl start docker. service :. echo "displaying lots of information about the Nginx service, like active(Running) If Nginx is not running, it will display as inactive, If something went wrong and Nginx couldn’t load, you’ll see a red status failed" sudo docker systemctl status echo "Stop the nxing service" sudo systemctl stop nginx echo "Start the nginx service" sudo docker systemctl start nginx echo " docker containers in running state. ps stands for “Process Status”"
sudo docker ps echo " running containers and stop containers all are display status."
sudo docker ps -a echo "Existing container name rename" sudo docker rename My_Container My_New_Container echo "start the container"
sudo docker start echo "stop the container"
sudo docker stop echo "It is used for suspends all processes in the specified containers"
sudo docker pause echo "Unpause all processes within one or more containers" sudo docker unpause echo "Restart one or more containers"
sudo docker restart echo "statistics of container, This command allows users to display the ps output for the main process of a given container ID or name" sudo docker top echo "Running docker stats on all running containers and multiple containers by name and id" sudo docker status echo "It will be remove containers"
sudo docker rm echo "Remove the images"
sudo docker rmi echo "It will be imediatly delete"
sudo docker kill echo "Log in to a Docker registry"
sudo docker login

Sucessfully added All Commands