Assignment for docker day1

DevOps

MOTOSHARE 🚗🏍️
Turning Idle Vehicles into Shared Rides & Earnings

From Idle to Income. From Parked to Purpose.
Earn by Sharing, Ride by Renting.
Where Owners Earn, Riders Move.
Owners Earn. Riders Move. Motoshare Connects.

With Motoshare, every parked vehicle finds a purpose. Owners earn. Renters ride.
🚀 Everyone wins.

Start Your Journey with Motoshare

Q1. Explain What is Docker Container with image?

A container which contains our image with root file system, 1 PID, 1 NW, 1 MNT, 1 USER.

Q2. What is the difference between docker stop and docker kill?

docker stop and docker kill doing the same thing only the internal process have difference. Both stops a running container to an exit state.

docker create –name vin6 httpd
docker start vin6
docker ps
docker stop vin6
docker ps -a
docker start vin6
docker pause vin6
docker ps -a
docker unpause vin6
docker images -a
docker ps -a
docker stop vin6
docker restart vin6
docker ps
docker kill vin6

Q3. What is the differenece between docker pause and docker unpause?

Docker pause is used to pause the running container which can be resumed with unpause. But is we stop or kill we can not unpause but we can restart.

docker create –name vin6 httpd
docker start vin6
docker ps
docker stop vin6
docker ps -a
docker start vin6
docker pause vin6
docker ps -a
docker unpause vin6
docker images -a
docker ps -a
docker stop vin6
docker restart vin6
docker ps
docker kill vin6