TP Docker
TP Docker
Cloud Computing
A.U. : 2024/2025
Taecher : Rahma Haouas
I) Basic Commands
Test Docker
docker run hello-world
Retrieve an Image
docker pull busybox
The pull command retrieves the busybox image from the Docker registry and saves it to our
system.
You can use the following command to display a list of all images available on your system:
docker images
Running the run command with the -it flags attaches an interactive TTY to the container. This
allows you to execute multiple commands inside the container.
Remove a Container
We saw earlier that we can still see remnants of a container even after it exits by running
docker ps -a.
Throughout this tutorial, you’ll run multiple containers, and leaving unused containers will
consume disk space.
As a general rule, it’s good practice to clean up containers once you're done with them.
FROM ubuntu